home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1999 April: Mac OS SDK / Dev.CD Apr 99 SDK1.toast / Development Kits / Interfaces&Libraries / Universal / Interfaces / PInterfaces / OCEAuthDir.p < prev    next >
Encoding:
Text File  |  1998-08-17  |  173.6 KB  |  4,743 lines  |  [TEXT/MPS ]

  1. {
  2.      File:        OCEAuthDir.p
  3.  
  4.      Contains:    Apple Open Collaboration Environment Authentication Interfaces.
  5.  
  6.      Version:    Technology:    AOCE Toolbox 1.02
  7.                  Release:    Universal Interfaces 3.2
  8.  
  9.      Copyright:    © 1994-1998 by Apple Computer, Inc., all rights reserved.
  10.  
  11.      Bugs?:        For bug reports, consult the following page on
  12.                  the World Wide Web:
  13.  
  14.                      http://developer.apple.com/bugreporter/
  15.  
  16. }
  17. {$IFC UNDEFINED UsingIncludes}
  18. {$SETC UsingIncludes := 0}
  19. {$ENDC}
  20.  
  21. {$IFC NOT UsingIncludes}
  22.  UNIT OCEAuthDir;
  23.  INTERFACE
  24. {$ENDC}
  25.  
  26. {$IFC UNDEFINED __OCEAUTHDIR__}
  27. {$SETC __OCEAUTHDIR__ := 1}
  28.  
  29. {$I+}
  30. {$SETC OCEAuthDirIncludes := UsingIncludes}
  31. {$SETC UsingIncludes := 1}
  32.  
  33. {$IFC UNDEFINED __APPLETALK__}
  34. {$I AppleTalk.p}
  35. {$ENDC}
  36. {$IFC UNDEFINED __FILES__}
  37. {$I Files.p}
  38. {$ENDC}
  39. {$IFC UNDEFINED __OSUTILS__}
  40. {$I OSUtils.p}
  41. {$ENDC}
  42. {$IFC UNDEFINED __MACTYPES__}
  43. {$I MacTypes.p}
  44. {$ENDC}
  45.  
  46. {$IFC UNDEFINED __OCE__}
  47. {$I OCE.p}
  48. {$ENDC}
  49.  
  50.  
  51. {$PUSH}
  52. {$ALIGN MAC68K}
  53. {$LibExport+}
  54.  
  55. {***************************************************************************}
  56.  
  57. CONST
  58.     kRC4KeySizeInBytes            = 8;                            {  size of an RC4 key  }
  59.     kRefNumUnknown                = 0;
  60.  
  61.     kEnumDistinguishedNameBit    = 0;
  62.     kEnumAliasBit                = 1;
  63.     kEnumPseudonymBit            = 2;
  64.     kEnumDNodeBit                = 3;
  65.     kEnumInvisibleBit            = 4;
  66.  
  67. { Values of DirEnumChoices }
  68.     kEnumDistinguishedNameMask    = $00000001;
  69.     kEnumAliasMask                = $00000002;
  70.     kEnumPseudonymMask            = $00000004;
  71.     kEnumDNodeMask                = $00000008;
  72.     kEnumInvisibleMask            = $00000010;
  73.     kEnumAllMask                = $0000001F;
  74.  
  75.  
  76. TYPE
  77.     DirEnumChoices                        = UInt32;
  78. { Values of DirSortOption }
  79.  
  80. CONST
  81.     kSortByName                    = 0;
  82.     kSortByType                    = 1;
  83.  
  84.  
  85. { Values of DirSortDirection }
  86.     kSortForwards                = 0;
  87.     kSortBackwards                = 1;
  88.  
  89. { Values of DirMatchWith }
  90.     kMatchAll                    = 0;
  91.     kExactMatch                    = 1;
  92.     kBeginsWith                    = 2;
  93.     kEndingWith                    = 3;
  94.     kContaining                    = 4;
  95.  
  96.  
  97. TYPE
  98.     DirMatchWith                        = SInt8;
  99.  
  100. CONST
  101.     kCurrentOCESortVersion        = 1;
  102.  
  103. {  Access controls are implemented on three levels:
  104.  *      DNode, Record, and Attribute Type levels
  105.  *  Some access control bits apply to the container itself, and some apply to its contents.
  106.  *
  107.  *  The Catalog Toolbox supports six functions.  These calls are:
  108.  *  DSGetDNodeAccessControl : to get Access Controls at the DNode level
  109.  *    DSGetRecordAccessControl  : to get Access Controls at the record level
  110.  *  DSGetAttributeAccessControl : to get Access Privileges at the attribute type level
  111.  * 
  112.  *  The GetXXXAccessControl calls will return access control masks for various categories
  113.  *  of users.  Please refer to the access control document for a description of the
  114.  *  categories of users.  In general these are:
  115.  *      ThisRecordOwner         - means the identity of the record itself
  116.  *      Friends                  - means any one of the assigned friends for the record
  117.  *      AuthenticatedInDNode     - means any valid user that is an authenticated entity
  118.  *          in the DNode in which this record is located
  119.  *      AuthenticatedInDirectory - means any valid authenticated catalog user
  120.  *      Guest                      - means an unauthenticated user.
  121.  *  Bit masks for various permitted access controls are defined below.
  122.  *
  123.  *  GetXXXAccessControl calls will return access control masks for various categories of
  124.  *  users for this record. In addition they also return the level of access controls
  125.  *  that the user (who is making the GetXXXAccessControl call) has for the DNode,
  126.  *  record, or attribute type.
  127.  *
  128.  *  For records, the access control granted will be minimum of the DNode access
  129.  *  control and record access control masks.  For example, to add an attribute type to a
  130.  *  record, a user must have access control kCreateAttributeTypes at the record and
  131.  *  DNode levels.  Similarly, at the attribute type level, access controls will be the
  132.  *  minimum of the DNode, record, and attribute type access controls.
  133.  *
  134.  *  
  135.  }
  136. { access privileges bit numbers }
  137.     kSeeBit                        = 0;
  138.     kAddBit                        = 1;
  139.     kDeleteBit                    = 2;
  140.     kChangeBit                    = 3;
  141.     kRenameBit                    = 4;
  142.     kChangePrivsBit                = 5;
  143.     kSeeFoldersBit                = 6;
  144.  
  145. { Values of AccessMask }
  146.     kSeeMask                    = $00000001;
  147.     kAddMask                    = $00000002;
  148.     kDeleteMask                    = $00000004;
  149.     kChangeMask                    = $00000008;
  150.     kRenameMask                    = $00000010;
  151.     kChangePrivsMask            = $00000020;
  152.     kSeeFoldersMask                = $00000040;
  153.  
  154.     kAllPrivs                    = $0000007F;
  155.     kNoPrivs                    = 0;
  156.  
  157. {
  158.  
  159. kSupportsDNodeNumberBit:
  160. If this bit is set, a DNode can be referenced using DNodeNumbers. 
  161. RecordLocationInfo can be specified using DNodeNumber and PathName component can be nil. 
  162. If this bit is not set, a DNode can be referenced only by PathName to the DNode. In the 
  163. later case DNodeNumber component inside record location info must be set to zero.
  164.  
  165. kSupportsRecordCreationIDBit:
  166. If this bit is set, a record can be referenced by specifying CreationID 
  167. in most catalog manager calls. If this bit is not set recordName and recordType are 
  168. required in the recordID specification for all catalog manager calls.
  169.  
  170. kSupportsAttributeCreationIDBit:
  171. If this bit is set, an attribute value can be obtained by specifying it's 
  172. CreationID in Lookup call staring point and also can be used in operations 
  173. like DeleteAttributeValue and ChangeAttributeValue an Attribute can be 
  174. specified by AttributeType and CreationID.
  175.  
  176. *************************************************************************
  177. Implicit assumption with creationID's and dNodeNumbers are, when supported
  178. they are persistent and will preserved across boots and life of the system.
  179. *************************************************************************
  180.  
  181. Following three bits are for determining the sort order in enumeration.
  182. kSupportsMatchAllBit:
  183. If this bit is set, enumeration of all the records is supported
  184.  
  185. kSupportsBeginsWithBit:
  186. If this bit is set, enumeration of records matching prefix (e.g. Begin with abc)
  187. is supported
  188.  
  189. kSupportsExactMatchBit:
  190. If this bit is set, existence of a record matching exact matchNameString and recordType
  191. is supported.
  192.  
  193. kSupportsEndsWithBit:
  194. If this bit is set, enumeration of records matching suffix (e.g. end with abc)
  195. is supported.
  196.  
  197. kSupportsContainsBit:
  198. If this bit is set, enumeration of records containing a matchNameString (e.g. containing abc)
  199. is supported
  200.  
  201.  
  202. Implicit assumption in all these is, a record type can be specified either as one of the above or
  203. a type list(more then one) to match exact type.
  204. The Following four bits will indicate sort ordering in enumeration.
  205.  
  206. kSupportsOrderedEnumerationBit:
  207. If this bit is set, Enumerated records or in some order possibly in name order.
  208.  
  209. kCanSupportNameOrderBit:
  210. If this is set, catalog will support sortbyName option in Enumerate.
  211.  
  212. kCanSupportTypeOrderBit:
  213. If this bit is set, catalog will support sortbyType option in enumearte.
  214.  
  215. kSupportSortBackwardsBit:
  216. If this bit is set, catalog supports backward sorting.
  217.  
  218. kSupportIndexRatioBit:
  219. If this bit is set, it indicates that enumeration will return approximate position
  220. of a record (percentile) among all records.
  221.  
  222. kSupportsEnumerationContinueBit:
  223. If this bit is set, catalog supports enumeration continue.
  224.  
  225. kSupportsLookupContinueBit:
  226. If this bit is set, catalog supports lookup continue.
  227.  
  228. kSupportsEnumerateAttributeTypeContinueBit:
  229. If this bit is set, catalog supports EnumerateAttributeType continue.
  230.  
  231. kSupportsEnumeratePseudonymContinueBit:
  232. If this bit is set, catalog supports EnumeratePseudonym continue.
  233.  
  234. kSupportsAliasesBit:
  235. If this bit is set, catalog supports create/delte/enumerate 
  236. of Alias Records.
  237.  
  238. kSupportPseudonymBit: 
  239. If this bit is set, catalog supports create/delte/enumerate of 
  240. pseudonyms for a record.
  241.  
  242. kSupportsPartialPathNameBit:
  243. If this bit is set, catalog nodes can be specified using DNodeNumber of a 
  244. intermediate DNode and a partial name starting from that DNode to the intended 
  245. DNode.
  246.  
  247. kSupportsAuthenticationBit:
  248. If this bit is set, catalog supports authentication manager calls.
  249.  
  250. kSupportsProxiesBit:
  251. If this bit is set, catalog supports proxy related calls in authentication manager. 
  252.  
  253. kSupportsFindRecordBit:
  254. If this bit is set, catalog supports find record call.
  255.  
  256. Bits and corresponding masks are as defined below.
  257. }
  258.     kSupportsDNodeNumberBit        = 0;
  259.     kSupportsRecordCreationIDBit = 1;
  260.     kSupportsAttributeCreationIDBit = 2;
  261.     kSupportsMatchAllBit        = 3;
  262.     kSupportsBeginsWithBit        = 4;
  263.     kSupportsExactMatchBit        = 5;
  264.     kSupportsEndsWithBit        = 6;
  265.     kSupportsContainsBit        = 7;
  266.     kSupportsOrderedEnumerationBit = 8;
  267.     kCanSupportNameOrderBit        = 9;
  268.     kCanSupportTypeOrderBit        = 10;
  269.     kSupportSortBackwardsBit    = 11;
  270.     kSupportIndexRatioBit        = 12;
  271.     kSupportsEnumerationContinueBit = 13;
  272.     kSupportsLookupContinueBit    = 14;
  273.     kSupportsEnumerateAttributeTypeContinueBit = 15;
  274.     kSupportsEnumeratePseudonymContinueBit = 16;
  275.     kSupportsAliasesBit            = 17;
  276.     kSupportsPseudonymsBit        = 18;
  277.     kSupportsPartialPathNamesBit = 19;
  278.     kSupportsAuthenticationBit    = 20;
  279.     kSupportsProxiesBit            = 21;
  280.     kSupportsFindRecordBit        = 22;
  281.  
  282. { values of DirGestalt }
  283.     kSupportsDNodeNumberMask    = $00000001;
  284.     kSupportsRecordCreationIDMask = $00000002;
  285.     kSupportsAttributeCreationIDMask = $00000004;
  286.     kSupportsMatchAllMask        = $00000008;
  287.     kSupportsBeginsWithMask        = $00000010;
  288.     kSupportsExactMatchMask        = $00000020;
  289.     kSupportsEndsWithMask        = $00000040;
  290.     kSupportsContainsMask        = $00000080;
  291.     kSupportsOrderedEnumerationMask = $00000100;
  292.     kCanSupportNameOrderMask    = $00000200;
  293.     kCanSupportTypeOrderMask    = $00000400;
  294.     kSupportSortBackwardsMask    = $00000800;
  295.     kSupportIndexRatioMask        = $00001000;
  296.     kSupportsEnumerationContinueMask = $00002000;
  297.     kSupportsLookupContinueMask    = $00004000;
  298.     kSupportsEnumerateAttributeTypeContinueMask = $00008000;
  299.     kSupportsEnumeratePseudonymContinueMask = $00010000;
  300.     kSupportsAliasesMask        = $00020000;
  301.     kSupportsPseudonymsMask        = $00040000;
  302.     kSupportsPartialPathNamesMask = $00080000;
  303.     kSupportsAuthenticationMask    = $00100000;
  304.     kSupportsProxiesMask        = $00200000;
  305.     kSupportsFindRecordMask        = $00400000;
  306.  
  307.  
  308. { Values of AuthLocalIdentityOp }
  309.     kAuthLockLocalIdentityOp    = 1;
  310.     kAuthUnlockLocalIdentityOp    = 2;
  311.     kAuthLocalIdentityNameChangeOp = 3;
  312.  
  313. { Values of AuthLocalIdentityLockAction }
  314.     kAuthLockPending            = 1;
  315.     kAuthLockWillBeDone            = 2;
  316.  
  317.  
  318. { Values of AuthNotifications }
  319.     kNotifyLockBit                = 0;
  320.     kNotifyUnlockBit            = 1;
  321.     kNotifyNameChangeBit        = 2;
  322.  
  323.     kNotifyLockMask                = $00000001;
  324.     kNotifyUnlockMask            = $00000002;
  325.     kNotifyNameChangeMask        = $00000004;
  326.  
  327.     kPersonalDirectoryFileCreator = 'kl03';
  328.     kPersonalDirectoryFileType    = 'pabt';
  329.     kBusinessCardFileType        = 'bust';
  330.     kDirectoryFileType            = 'dirt';
  331.     kDNodeFileType                = 'dnod';
  332.     kDirsRootFileType            = 'drtt';
  333.     kRecordFileType                = 'rcrd';
  334.  
  335.  
  336. TYPE
  337.     DirSortOption                        = UInt16;
  338.     DirSortDirection                    = UInt16;
  339.     AccessMask                            = UInt32;
  340.     DirGestalt                            = UInt32;
  341.     AuthLocalIdentityOp                    = UInt32;
  342.     AuthLocalIdentityLockAction            = UInt32;
  343.     AuthNotifications                    = UInt32;
  344.     DNodeIDPtr = ^DNodeID;
  345.     DNodeID = RECORD
  346.         dNodeNumber:            DNodeNum;                                {  dNodenumber   }
  347.         reserved1:                LONGINT;
  348.         name:                    RStringPtr;
  349.         reserved2:                LONGINT;
  350.     END;
  351.  
  352.     DirEnumSpecPtr = ^DirEnumSpec;
  353.     DirEnumSpec = RECORD
  354.         enumFlag:                DirEnumChoices;
  355.         indexRatio:                UInt16;                                    {  Approx Record Position between 1 and 100 If supported, 0 If not supported  }
  356.         CASE INTEGER OF
  357.         0: (
  358.             recordIdentifier:    LocalRecordID;
  359.             );
  360.         1: (
  361.             dNodeIdentifier:    DNodeID;
  362.             );
  363.     END;
  364.  
  365.     DirMetaInfoPtr = ^DirMetaInfo;
  366.     DirMetaInfo = RECORD
  367.         info:                    ARRAY [0..3] OF UInt32;
  368.     END;
  369.  
  370.     SLRVPtr = ^SLRV;
  371.     SLRV = RECORD
  372.         script:                    ScriptCode;                                {    Script code in which entries are sorted  }
  373.         language:                INTEGER;                                {    Language code in which entries are sorted  }
  374.         regionCode:                INTEGER;                                {    Region code in which entries are sorted  }
  375.         version:                INTEGER;                                {   version of oce sorting software  }
  376.     END;
  377.  
  378. { Catalog types and operations }
  379. { unique identifier for an identity }
  380.     AuthIdentity                        = UInt32;
  381. { Umbrella LocalIdentity }
  382.     LocalIdentity                        = AuthIdentity;
  383. { A DES key is 8 bytes of data }
  384.     DESKeyPtr = ^DESKey;
  385.     DESKey = RECORD
  386.         a:                        UInt32;
  387.         b:                        UInt32;
  388.     END;
  389.  
  390.     RC4Key                                = ARRAY [0..7] OF SignedByte;
  391.     AuthKeyType                            = UInt32;
  392. { key type followed by its data }
  393.     AuthKeyPtr = ^AuthKey;
  394.     AuthKey = RECORD
  395.         keyType:                AuthKeyType;
  396.         CASE INTEGER OF
  397.         0: (
  398.             des:                DESKey;
  399.             );
  400.         1: (
  401.             rc4:                RC4Key;
  402.             );
  403.     END;
  404.  
  405.     AuthParamBlockPtr = ^AuthParamBlock;
  406. { Fix parameter passing convention (#1274062) ggs, 8-7-95 }
  407. {$IFC TYPED_FUNCTION_POINTERS}
  408.     AuthIOCompletionProcPtr = PROCEDURE(paramBlock: AuthParamBlockPtr);
  409. {$ELSEC}
  410.     AuthIOCompletionProcPtr = Register68kProcPtr;
  411. {$ENDC}
  412.  
  413.     AuthIOCompletionUPP = UniversalProcPtr;
  414. {****************************************************************************
  415.  
  416.  
  417.         Authentication Manager operations 
  418.  
  419. ****************************************************************************}
  420. {
  421. kAuthResolveCreationID:
  422. userRecord will contain the user information whose creationID has to be
  423. returned. A client must make this call when he does not know the creaitionID.
  424. The creationID must be set to nil before making the call. The server will attempt
  425. to match the recordid's in the data base which match the user name and
  426. type in the record.  Depending on number of matchings, following
  427. results will be returned.
  428. Exactly One Match : CreationID in RecordID and also in buffer (if buffer is given)
  429. totalMatches = actualMatches = 1.
  430. > 1 Match:
  431.     Buffer is Large Enough:
  432.     totalMatches = actualMatches
  433.     Buffer will contain all the CIDs, kOCEAmbiguousMatches error.
  434. > 1 Match:
  435.     Buffer is not Large Enough:
  436.     totalMatches > actualMatches
  437.     Buffer will contain all the CIDs (equal to actualMatches), daMoreDataError error.
  438. 0 Matches:
  439.  kOCENoSuchRecord error
  440. }
  441.     AuthResolveCreationIDPBPtr = ^AuthResolveCreationIDPB;
  442.     AuthResolveCreationIDPB = RECORD
  443.         qLink:                    Ptr;
  444.         reserved1:                LONGINT;
  445.         reserved2:                LONGINT;
  446.         ioCompletion:            AuthIOCompletionUPP;
  447.         ioResult:                OSErr;
  448.         saveA5:                    UInt32;
  449.         reqCode:                INTEGER;
  450.         reserved:                ARRAY [0..1] OF LONGINT;
  451.         serverHint:                AddrBlock;
  452.         dsRefNum:                INTEGER;
  453.         callID:                    UInt32;
  454.         identity:                AuthIdentity;
  455.         gReserved1:                LONGINT;
  456.         gReserved2:                LONGINT;
  457.         gReserved3:                LONGINT;
  458.         clientData:                LONGINT;
  459.         userRecord:                RecordIDPtr;                            {   --> OCE name(Record) of the user  }
  460.         bufferLength:            UInt32;                                    {   --> Buffer Size to hold duplicate Info  }
  461.         buffer:                    Ptr;                                    {   --> Buffer  to hold duplicate Info  }
  462.         totalMatches:            UInt32;                                    {  <--  Total Number of matching names found  }
  463.         actualMatches:            UInt32;                                    {  <--  Number of matches returned in the buffer  }
  464.     END;
  465.  
  466. {
  467. kAuthBindSpecificIdentity:
  468. userRecord will contain the user information whose identity has to be
  469. verified. userKey will contain the userKey. An Identity is returned which
  470. binds the key and the userRecord. The identity returned can be used in the 'identity'
  471. field in the header portion (AuthParamHeader) for authenticating the Catalog and
  472. Authentication manager calls.
  473. }
  474.     AuthBindSpecificIdentityPBPtr = ^AuthBindSpecificIdentityPB;
  475.     AuthBindSpecificIdentityPB = RECORD
  476.         qLink:                    Ptr;
  477.         reserved1:                LONGINT;
  478.         reserved2:                LONGINT;
  479.         ioCompletion:            AuthIOCompletionUPP;
  480.         ioResult:                OSErr;
  481.         saveA5:                    UInt32;
  482.         reqCode:                INTEGER;
  483.         reserved:                ARRAY [0..1] OF LONGINT;
  484.         serverHint:                AddrBlock;
  485.         dsRefNum:                INTEGER;
  486.         callID:                    UInt32;
  487.         identity:                AuthIdentity;
  488.         gReserved1:                LONGINT;
  489.         gReserved2:                LONGINT;
  490.         gReserved3:                LONGINT;
  491.         clientData:                LONGINT;
  492.         userIdentity:            AuthIdentity;                            {  <--  binding identity  }
  493.         userRecord:                RecordIDPtr;                            {   --> OCE name(Record) of the user  }
  494.         userKey:                AuthKeyPtr;                                {   --> OCE Key for the user  }
  495.     END;
  496.  
  497. {
  498. kAuthUnbindSpecificIdentity:
  499. This call will unbind the userRecord and key which were bind earlier.
  500. }
  501.     AuthUnbindSpecificIdentityPBPtr = ^AuthUnbindSpecificIdentityPB;
  502.     AuthUnbindSpecificIdentityPB = RECORD
  503.         qLink:                    Ptr;
  504.         reserved1:                LONGINT;
  505.         reserved2:                LONGINT;
  506.         ioCompletion:            AuthIOCompletionUPP;
  507.         ioResult:                OSErr;
  508.         saveA5:                    UInt32;
  509.         reqCode:                INTEGER;
  510.         reserved:                ARRAY [0..1] OF LONGINT;
  511.         serverHint:                AddrBlock;
  512.         dsRefNum:                INTEGER;
  513.         callID:                    UInt32;
  514.         identity:                AuthIdentity;
  515.         gReserved1:                LONGINT;
  516.         gReserved2:                LONGINT;
  517.         gReserved3:                LONGINT;
  518.         clientData:                LONGINT;
  519.         userIdentity:            AuthIdentity;                            {   --> identity to be deleted  }
  520.     END;
  521.  
  522.  
  523. {
  524. kAuthGetSpecificIdentityInfo:
  525. This call will return the userRecord for the given identity. Note: key is not
  526. returned because this would compromise security.
  527. }
  528.     AuthGetSpecificIdentityInfoPBPtr = ^AuthGetSpecificIdentityInfoPB;
  529.     AuthGetSpecificIdentityInfoPB = RECORD
  530.         qLink:                    Ptr;
  531.         reserved1:                LONGINT;
  532.         reserved2:                LONGINT;
  533.         ioCompletion:            AuthIOCompletionUPP;
  534.         ioResult:                OSErr;
  535.         saveA5:                    UInt32;
  536.         reqCode:                INTEGER;
  537.         reserved:                ARRAY [0..1] OF LONGINT;
  538.         serverHint:                AddrBlock;
  539.         dsRefNum:                INTEGER;
  540.         callID:                    UInt32;
  541.         identity:                AuthIdentity;
  542.         gReserved1:                LONGINT;
  543.         gReserved2:                LONGINT;
  544.         gReserved3:                LONGINT;
  545.         clientData:                LONGINT;
  546.         userIdentity:            AuthIdentity;                            {   --> identity of initiator  }
  547.         userRecord:                RecordIDPtr;                            {  <--  OCE name(Record) of the user  }
  548.     END;
  549.  
  550.  
  551. {
  552. kAuthAddKey:
  553. userRecord will contain the user information whose identity has to be
  554. created. userKey will point to the key to be created. password points to
  555. an RString containing the password used to generate the key.
  556. }
  557.     AuthAddKeyPBPtr = ^AuthAddKeyPB;
  558.     AuthAddKeyPB = RECORD
  559.         qLink:                    Ptr;
  560.         reserved1:                LONGINT;
  561.         reserved2:                LONGINT;
  562.         ioCompletion:            AuthIOCompletionUPP;
  563.         ioResult:                OSErr;
  564.         saveA5:                    UInt32;
  565.         reqCode:                INTEGER;
  566.         reserved:                ARRAY [0..1] OF LONGINT;
  567.         serverHint:                AddrBlock;
  568.         dsRefNum:                INTEGER;
  569.         callID:                    UInt32;
  570.         identity:                AuthIdentity;
  571.         gReserved1:                LONGINT;
  572.         gReserved2:                LONGINT;
  573.         gReserved3:                LONGINT;
  574.         clientData:                LONGINT;
  575.         userRecord:                RecordIDPtr;                            {   --> OCE name(Record) of the user  }
  576.         userKey:                AuthKeyPtr;                                {  <--  OCE Key for the user  }
  577.         password:                RStringPtr;                                {   --> Pointer to password string  }
  578.     END;
  579.  
  580. {
  581. kAuthChangeKey:
  582. userRecord will contain the user information whose identity has to be
  583. created. userKey will point to the key to be created. password points to
  584. an RString containing the password used to generate the key.
  585. }
  586.     AuthChangeKeyPBPtr = ^AuthChangeKeyPB;
  587.     AuthChangeKeyPB = RECORD
  588.         qLink:                    Ptr;
  589.         reserved1:                LONGINT;
  590.         reserved2:                LONGINT;
  591.         ioCompletion:            AuthIOCompletionUPP;
  592.         ioResult:                OSErr;
  593.         saveA5:                    UInt32;
  594.         reqCode:                INTEGER;
  595.         reserved:                ARRAY [0..1] OF LONGINT;
  596.         serverHint:                AddrBlock;
  597.         dsRefNum:                INTEGER;
  598.         callID:                    UInt32;
  599.         identity:                AuthIdentity;
  600.         gReserved1:                LONGINT;
  601.         gReserved2:                LONGINT;
  602.         gReserved3:                LONGINT;
  603.         clientData:                LONGINT;
  604.         userRecord:                RecordIDPtr;                            {   --> OCE name(Record) of the user  }
  605.         userKey:                AuthKeyPtr;                                {  <--  New OCE Key for the user  }
  606.         password:                RStringPtr;                                {   -->Pointer to the new password string  }
  607.     END;
  608.  
  609. {
  610. AuthDeleteKey:
  611. userRecord will contain the user information whose Key has to be deleted.
  612. }
  613.     AuthDeleteKeyPBPtr = ^AuthDeleteKeyPB;
  614.     AuthDeleteKeyPB = RECORD
  615.         qLink:                    Ptr;
  616.         reserved1:                LONGINT;
  617.         reserved2:                LONGINT;
  618.         ioCompletion:            AuthIOCompletionUPP;
  619.         ioResult:                OSErr;
  620.         saveA5:                    UInt32;
  621.         reqCode:                INTEGER;
  622.         reserved:                ARRAY [0..1] OF LONGINT;
  623.         serverHint:                AddrBlock;
  624.         dsRefNum:                INTEGER;
  625.         callID:                    UInt32;
  626.         identity:                AuthIdentity;
  627.         gReserved1:                LONGINT;
  628.         gReserved2:                LONGINT;
  629.         gReserved3:                LONGINT;
  630.         clientData:                LONGINT;
  631.         userRecord:                RecordIDPtr;                            {   --> OCE name(Record) of the user  }
  632.     END;
  633.  
  634. { AuthPasswordToKey: Converts an RString into a key. }
  635.     AuthPasswordToKeyPBPtr = ^AuthPasswordToKeyPB;
  636.     AuthPasswordToKeyPB = RECORD
  637.         qLink:                    Ptr;
  638.         reserved1:                LONGINT;
  639.         reserved2:                LONGINT;
  640.         ioCompletion:            AuthIOCompletionUPP;
  641.         ioResult:                OSErr;
  642.         saveA5:                    UInt32;
  643.         reqCode:                INTEGER;
  644.         reserved:                ARRAY [0..1] OF LONGINT;
  645.         serverHint:                AddrBlock;
  646.         dsRefNum:                INTEGER;
  647.         callID:                    UInt32;
  648.         identity:                AuthIdentity;
  649.         gReserved1:                LONGINT;
  650.         gReserved2:                LONGINT;
  651.         gReserved3:                LONGINT;
  652.         clientData:                LONGINT;
  653.         userRecord:                RecordIDPtr;                            {   --> OCE name(Record) of the user  }
  654.         key:                    AuthKeyPtr;                                {  <--   }
  655.         password:                RStringPtr;                                {   -->Pointer to the new password string  }
  656.     END;
  657.  
  658. {
  659. kAuthGetCredentials:
  660. userRecord will contain the user information whose identity has to be
  661. kMailDeletedMask. keyType (e.g. asDESKey) will indicate what type of key has to
  662. be deleted.
  663. }
  664.     AuthGetCredentialsPBPtr = ^AuthGetCredentialsPB;
  665.     AuthGetCredentialsPB = RECORD
  666.         qLink:                    Ptr;
  667.         reserved1:                LONGINT;
  668.         reserved2:                LONGINT;
  669.         ioCompletion:            AuthIOCompletionUPP;
  670.         ioResult:                OSErr;
  671.         saveA5:                    UInt32;
  672.         reqCode:                INTEGER;
  673.         reserved:                ARRAY [0..1] OF LONGINT;
  674.         serverHint:                AddrBlock;
  675.         dsRefNum:                INTEGER;
  676.         callID:                    UInt32;
  677.         identity:                AuthIdentity;
  678.         gReserved1:                LONGINT;
  679.         gReserved2:                LONGINT;
  680.         gReserved3:                LONGINT;
  681.         clientData:                LONGINT;
  682.         userIdentity:            AuthIdentity;                            {   --> identity of initiator  }
  683.         recipient:                RecordIDPtr;                            {   --> OCE name of recipient  }
  684.         sessionKey:                AuthKeyPtr;                                {  <--  session key  }
  685.         expiry:                    UTCTime;                                {  <--> desired/actual expiry  }
  686.         credentialsLength:        UInt32;                                    {  <--> max/actual credentials size  }
  687.         credentials:            Ptr;                                    {  <--  buffer where credentials are returned  }
  688.     END;
  689.  
  690. {
  691. AuthDecryptCredentialsPB:
  692. Changes:
  693. userKey is changed userIdentity.
  694. userRecord is changed to initiatorRecord. User must supply buffer
  695. to hold initiatorRecord.
  696. agentList has changed to agent. There wil be no call back.
  697. User must supply buffer to hold agent Record.
  698. An additional boolean parameter 'hasAgent' is included.
  699. Toolbox will set this if an 'Agent' record is found in the
  700. credentials. If RecordIDPtr is 'nil', no agent record will
  701. be copied. However user can examine 'hasAgent', If true user
  702. can reissue this call with apprpriate buffer for getting a recordID.
  703. agent has changed to intermediary.  User must supply buffer to hold 
  704. intermediary Record.  The toolbox will set 'hasIntermediary' if an
  705. 'intermediary' record is found in the credentials. 
  706. }
  707.     AuthDecryptCredentialsPBPtr = ^AuthDecryptCredentialsPB;
  708.     AuthDecryptCredentialsPB = RECORD
  709.         qLink:                    Ptr;
  710.         reserved1:                LONGINT;
  711.         reserved2:                LONGINT;
  712.         ioCompletion:            AuthIOCompletionUPP;
  713.         ioResult:                OSErr;
  714.         saveA5:                    UInt32;
  715.         reqCode:                INTEGER;
  716.         reserved:                ARRAY [0..1] OF LONGINT;
  717.         serverHint:                AddrBlock;
  718.         dsRefNum:                INTEGER;
  719.         callID:                    UInt32;
  720.         identity:                AuthIdentity;
  721.         gReserved1:                LONGINT;
  722.         gReserved2:                LONGINT;
  723.         gReserved3:                LONGINT;
  724.         clientData:                LONGINT;
  725.         userIdentity:            AuthIdentity;                            {   --> user's Identity  }
  726.         initiatorRecord:        RecordIDPtr;                            {  <--  OCE name of the initiator  }
  727.         sessionKey:                AuthKeyPtr;                                {  <--  session key  }
  728.         expiry:                    UTCTime;                                {  <--  credentials expiry time  }
  729.         credentialsLength:        UInt32;                                    {   --> actual credentials size  }
  730.         credentials:            Ptr;                                    {   --> credentials to be decrypted  }
  731.         issueTime:                UTCTime;                                {  <--  credentials expiry time  }
  732.         hasIntermediary:        BOOLEAN;                                {  <--  if true, An intermediary Record was found in credentials  }
  733.         filler1:                BOOLEAN;
  734.         intermediary:            RecordIDPtr;                            {  <--  recordID of the intermediary  }
  735.     END;
  736.  
  737.  
  738.     AuthMakeChallengePBPtr = ^AuthMakeChallengePB;
  739.     AuthMakeChallengePB = RECORD
  740.         qLink:                    Ptr;
  741.         reserved1:                LONGINT;
  742.         reserved2:                LONGINT;
  743.         ioCompletion:            AuthIOCompletionUPP;
  744.         ioResult:                OSErr;
  745.         saveA5:                    UInt32;
  746.         reqCode:                INTEGER;
  747.         reserved:                ARRAY [0..1] OF LONGINT;
  748.         serverHint:                AddrBlock;
  749.         dsRefNum:                INTEGER;
  750.         callID:                    UInt32;
  751.         identity:                AuthIdentity;
  752.         gReserved1:                LONGINT;
  753.         gReserved2:                LONGINT;
  754.         gReserved3:                LONGINT;
  755.         clientData:                LONGINT;
  756.         key:                    AuthKeyPtr;                                {   --> UnEncrypted SessionKey  }
  757.         challenge:                Ptr;                                    {  <--  Encrypted Challenge  }
  758.         challengeBufferLength:    UInt32;                                    {   ->length of challenge buffer  }
  759.         challengeLength:        UInt32;                                    {   <-length of Encrypted Challenge  }
  760.     END;
  761.  
  762.     AuthMakeReplyPBPtr = ^AuthMakeReplyPB;
  763.     AuthMakeReplyPB = RECORD
  764.         qLink:                    Ptr;
  765.         reserved1:                LONGINT;
  766.         reserved2:                LONGINT;
  767.         ioCompletion:            AuthIOCompletionUPP;
  768.         ioResult:                OSErr;
  769.         saveA5:                    UInt32;
  770.         reqCode:                INTEGER;
  771.         reserved:                ARRAY [0..1] OF LONGINT;
  772.         serverHint:                AddrBlock;
  773.         dsRefNum:                INTEGER;
  774.         callID:                    UInt32;
  775.         identity:                AuthIdentity;
  776.         gReserved1:                LONGINT;
  777.         gReserved2:                LONGINT;
  778.         gReserved3:                LONGINT;
  779.         clientData:                LONGINT;
  780.         key:                    AuthKeyPtr;                                {   --> UnEncrypted SessionKey  }
  781.         challenge:                Ptr;                                    {   --> Encrypted Challenge  }
  782.         reply:                    Ptr;                                    {  <--  Encrypted Reply  }
  783.         replyBufferLength:        UInt32;                                    {   -->length of challenge buffer  }
  784.         challengeLength:        UInt32;                                    {   --> length of Encrypted Challenge  }
  785.         replyLength:            UInt32;                                    {  <--  length of Encrypted Reply  }
  786.     END;
  787.  
  788.     AuthVerifyReplyPBPtr = ^AuthVerifyReplyPB;
  789.     AuthVerifyReplyPB = RECORD
  790.         qLink:                    Ptr;
  791.         reserved1:                LONGINT;
  792.         reserved2:                LONGINT;
  793.         ioCompletion:            AuthIOCompletionUPP;
  794.         ioResult:                OSErr;
  795.         saveA5:                    UInt32;
  796.         reqCode:                INTEGER;
  797.         reserved:                ARRAY [0..1] OF LONGINT;
  798.         serverHint:                AddrBlock;
  799.         dsRefNum:                INTEGER;
  800.         callID:                    UInt32;
  801.         identity:                AuthIdentity;
  802.         gReserved1:                LONGINT;
  803.         gReserved2:                LONGINT;
  804.         gReserved3:                LONGINT;
  805.         clientData:                LONGINT;
  806.         key:                    AuthKeyPtr;                                {   --> UnEncrypted SessionKey  }
  807.         challenge:                Ptr;                                    {   --> Encrypted Challenge  }
  808.         reply:                    Ptr;                                    {   --> Encrypted Reply  }
  809.         challengeLength:        UInt32;                                    {   --> length of Encrypted Challenge  }
  810.         replyLength:            UInt32;                                    {   --> length of Encrypted Reply  }
  811.     END;
  812.  
  813.  
  814.  
  815. {
  816. kAuthGetUTCTime:
  817. RLI will contain a valid RLI for a cluster server.
  818. UTC(GMT) time from one of the cluster server will be returned.
  819. An 'offSet' from UTC(GMT) to Mac Local Time will also be returned.
  820. If RLI is nil Map DA is used to determine UTC(GMT).
  821. Mac Local Time = theUTCTime + theUTCOffset.
  822. }
  823.     AuthGetUTCTimePBPtr = ^AuthGetUTCTimePB;
  824.     AuthGetUTCTimePB = RECORD
  825.         qLink:                    Ptr;
  826.         reserved1:                LONGINT;
  827.         reserved2:                LONGINT;
  828.         ioCompletion:            AuthIOCompletionUPP;
  829.         ioResult:                OSErr;
  830.         saveA5:                    UInt32;
  831.         reqCode:                INTEGER;
  832.         reserved:                ARRAY [0..1] OF LONGINT;
  833.         serverHint:                AddrBlock;
  834.         dsRefNum:                INTEGER;
  835.         callID:                    UInt32;
  836.         identity:                AuthIdentity;
  837.         gReserved1:                LONGINT;
  838.         gReserved2:                LONGINT;
  839.         gReserved3:                LONGINT;
  840.         clientData:                LONGINT;
  841.         pRLI:                    PackedRLIPtr;                            {   --> packed RLI of the Node, whose server's UTC is requested  }
  842.         theUTCTime:                UTCTime;                                {  <--  current UTC(GMT) Time utc seconds since 1/1/1904  }
  843.         theUTCOffset:            UTCOffset;                                {  <--  offset from UTC(GMT) seconds EAST of Greenwich  }
  844.     END;
  845.  
  846.  
  847. {
  848. kAuthMakeProxy:
  849. A user represented bu the 'userIdentity' can make a proxy using this call.
  850. 'recipient' is the RecordID of the recipient whom user is requesting proxy.
  851. 'intermediary' is the RecordID of the intermediary holding proxy for the user.
  852. 'firstValid' is time at which proxy becomes valid.
  853. 'expiry' is the time at which proxy must expire.
  854. 'proxyLength' will have the length of the buffer pointed by 'proxy' as input.
  855. When the call completes, it will hold the actual length of proxy. If the
  856. call completes 'kOCEMoreData' error, client can reissue the call with the
  857. buffer size as 'proxyLength' returned.
  858. expiry is a suggestion, and may be adjusted to be earlier by the ADAP/OCE server.
  859. The 'proxy' obtained like this might be used by the 'intermediary' to obtain credentials
  860. for the server using TradeProxyForCredentials call.
  861. authDataLength and authData are intended for possible future work, but are
  862. ignored for now.
  863. }
  864.     AuthMakeProxyPBPtr = ^AuthMakeProxyPB;
  865.     AuthMakeProxyPB = RECORD
  866.         qLink:                    Ptr;
  867.         reserved1:                LONGINT;
  868.         reserved2:                LONGINT;
  869.         ioCompletion:            AuthIOCompletionUPP;
  870.         ioResult:                OSErr;
  871.         saveA5:                    UInt32;
  872.         reqCode:                INTEGER;
  873.         reserved:                ARRAY [0..1] OF LONGINT;
  874.         serverHint:                AddrBlock;
  875.         dsRefNum:                INTEGER;
  876.         callID:                    UInt32;
  877.         identity:                AuthIdentity;
  878.         gReserved1:                LONGINT;
  879.         gReserved2:                LONGINT;
  880.         gReserved3:                LONGINT;
  881.         clientData:                LONGINT;
  882.         userIdentity:            AuthIdentity;                            {   --> identity of principal  }
  883.         recipient:                RecordIDPtr;                            {   --> OCE name of recipient  }
  884.         firstValid:                UTCTime;                                {   --> time at which proxy becomes valid  }
  885.         expiry:                    UTCTime;                                {   --> time at which proxy expires  }
  886.         authDataLength:            UInt32;                                    {   --> size of authorization data  }
  887.         authData:                Ptr;                                    {   --> pointer to authorization data  }
  888.         proxyLength:            UInt32;                                    {  <--> max/actual proxy size  }
  889.         proxy:                    Ptr;                                    {  <--> buffer where proxy is returned  }
  890.         intermediary:            RecordIDPtr;                            {   --> RecordID of intermediary  }
  891.     END;
  892.  
  893. {
  894. kAuthTradeProxyForCredentials:
  895. Using this call, intermediary holding a 'proxy' for a recipient may obtain credentials
  896. for that recipient. 'userIdentity' is the identity for the 'intermediary'.
  897. 'recipient' is the RecordID for whom credetials are requested.
  898. 'principal' is the RecordID of the user who created the proxy.
  899. 'proxyLength' is the length of data pointed by 'proxy.
  900. If the call is succesfull, credentials will be returned in the
  901. buffer pointed by 'credentials'. 'expiry' is the desired expiry time at input.
  902. When call succeds this will have expiry time of credentials.
  903. This is very similar to GetCredentials except that we (of course) need the proxy,
  904. but we also need the name of the principal who created the proxy.
  905. }
  906.     AuthTradeProxyForCredentialsPBPtr = ^AuthTradeProxyForCredentialsPB;
  907.     AuthTradeProxyForCredentialsPB = RECORD
  908.         qLink:                    Ptr;
  909.         reserved1:                LONGINT;
  910.         reserved2:                LONGINT;
  911.         ioCompletion:            AuthIOCompletionUPP;
  912.         ioResult:                OSErr;
  913.         saveA5:                    UInt32;
  914.         reqCode:                INTEGER;
  915.         reserved:                ARRAY [0..1] OF LONGINT;
  916.         serverHint:                AddrBlock;
  917.         dsRefNum:                INTEGER;
  918.         callID:                    UInt32;
  919.         identity:                AuthIdentity;
  920.         gReserved1:                LONGINT;
  921.         gReserved2:                LONGINT;
  922.         gReserved3:                LONGINT;
  923.         clientData:                LONGINT;
  924.         userIdentity:            AuthIdentity;                            {   --> identity of intermediary  }
  925.         recipient:                RecordIDPtr;                            {   --> OCE name of recipient  }
  926.         sessionKey:                AuthKeyPtr;                                {  <--  session key  }
  927.         expiry:                    UTCTime;                                {  <--> desired/actual expiry  }
  928.         credentialsLength:        UInt32;                                    {  <--> max/actual credentials size  }
  929.         credentials:            Ptr;                                    {  <--> buffer where credentials are returned  }
  930.         proxyLength:            UInt32;                                    {   --> actual proxy size  }
  931.         proxy:                    Ptr;                                    {   --> buffer containing proxy  }
  932.         principal:                RecordIDPtr;                            {   --> RecordID of principal  }
  933.     END;
  934.  
  935. { API for Local Identity Interface }
  936. {
  937. AuthGetLocalIdentityPB:
  938. A Collaborative application intended to work under the umbrella of LocalIdentity
  939. for the OCE toolbox will have to make this call to obtain LocalIdentity.
  940. If LocalIdentity has not been setup, then application will get
  941. 'kOCEOCESetupRequired.'. In this case application should put the dialog
  942. recommended by the OCE Setup document and guide the user through OCE Setup.
  943. If the OCESetup contains local identity, but user has not unlocked, it will get
  944. kOCELocalAuthenticationFail. In this case application should use SDPPromptForLocalIdentity
  945. to prompt user for the password.
  946. If a backGround application or stand alone code requires LocalIdentity, if it gets the
  947. OSErr from LocalIdentity and can not call SDPPromptForLocalIdentity, it should it self
  948. register with the toolbox using kAuthAddToLocalIdentityQueue call. It will be notified
  949. when a LocalIdentity gets created by a foreground application.
  950. }
  951.     AuthGetLocalIdentityPBPtr = ^AuthGetLocalIdentityPB;
  952.     AuthGetLocalIdentityPB = RECORD
  953.         qLink:                    Ptr;
  954.         reserved1:                LONGINT;
  955.         reserved2:                LONGINT;
  956.         ioCompletion:            AuthIOCompletionUPP;
  957.         ioResult:                OSErr;
  958.         saveA5:                    UInt32;
  959.         reqCode:                INTEGER;
  960.         reserved:                ARRAY [0..1] OF LONGINT;
  961.         serverHint:                AddrBlock;
  962.         dsRefNum:                INTEGER;
  963.         callID:                    UInt32;
  964.         identity:                AuthIdentity;
  965.         gReserved1:                LONGINT;
  966.         gReserved2:                LONGINT;
  967.         gReserved3:                LONGINT;
  968.         clientData:                LONGINT;
  969.         theLocalIdentity:        LocalIdentity;                            {  <--  LocalIdentity  }
  970.     END;
  971.  
  972. {
  973. kAuthUnlockLocalIdentity:
  974. The LocalIdentity can be created using this call.
  975. The userName and password correspond to the LocalIdentity setup.
  976. If the password matches, then collabIdentity will be returned.
  977. Typically SDPPromptForLocalIdentity call will make this call.
  978. All applications which are registered through kAuthAddToLocalIdentityQueue
  979. will be notified.
  980. }
  981.     AuthUnlockLocalIdentityPBPtr = ^AuthUnlockLocalIdentityPB;
  982.     AuthUnlockLocalIdentityPB = RECORD
  983.         qLink:                    Ptr;
  984.         reserved1:                LONGINT;
  985.         reserved2:                LONGINT;
  986.         ioCompletion:            AuthIOCompletionUPP;
  987.         ioResult:                OSErr;
  988.         saveA5:                    UInt32;
  989.         reqCode:                INTEGER;
  990.         reserved:                ARRAY [0..1] OF LONGINT;
  991.         serverHint:                AddrBlock;
  992.         dsRefNum:                INTEGER;
  993.         callID:                    UInt32;
  994.         identity:                AuthIdentity;
  995.         gReserved1:                LONGINT;
  996.         gReserved2:                LONGINT;
  997.         gReserved3:                LONGINT;
  998.         clientData:                LONGINT;
  999.         theLocalIdentity:        LocalIdentity;                            {  <--  LocalIdentity  }
  1000.         userName:                RStringPtr;                                {   --> userName  }
  1001.         password:                RStringPtr;                                {   -->user password  }
  1002.     END;
  1003.  
  1004. {
  1005. kAuthLockLocalIdentity:
  1006. With this call existing LocalIdentity can be locked. If the ASDeleteLocalIdetity
  1007. call fails with 'kOCEOperationDenied' error, name will contain the application which
  1008. denied the operation. This name will be supplied by the application
  1009. when it registered through kAuthAddToLocalIdentityQueue call
  1010. }
  1011.     AuthLockLocalIdentityPBPtr = ^AuthLockLocalIdentityPB;
  1012.     AuthLockLocalIdentityPB = RECORD
  1013.         qLink:                    Ptr;
  1014.         reserved1:                LONGINT;
  1015.         reserved2:                LONGINT;
  1016.         ioCompletion:            AuthIOCompletionUPP;
  1017.         ioResult:                OSErr;
  1018.         saveA5:                    UInt32;
  1019.         reqCode:                INTEGER;
  1020.         reserved:                ARRAY [0..1] OF LONGINT;
  1021.         serverHint:                AddrBlock;
  1022.         dsRefNum:                INTEGER;
  1023.         callID:                    UInt32;
  1024.         identity:                AuthIdentity;
  1025.         gReserved1:                LONGINT;
  1026.         gReserved2:                LONGINT;
  1027.         gReserved3:                LONGINT;
  1028.         clientData:                LONGINT;
  1029.         theLocalIdentity:        LocalIdentity;                            {   --> LocalIdentity  }
  1030.         name:                    StringPtr;                                {  <--  name of the app which denied delete  }
  1031.     END;
  1032.  
  1033. {$IFC TYPED_FUNCTION_POINTERS}
  1034.     NotificationProcPtr = FUNCTION(clientData: LONGINT; callValue: AuthLocalIdentityOp; actionValue: AuthLocalIdentityLockAction; identity: LocalIdentity): BOOLEAN;
  1035. {$ELSEC}
  1036.     NotificationProcPtr = ProcPtr;
  1037. {$ENDC}
  1038.  
  1039.     NotificationUPP = UniversalProcPtr;
  1040.     NotificationProc                    = NotificationUPP;
  1041. {
  1042. kAuthAddToLocalIdentityQueue:
  1043. An application requiring notification of locking/unlocking of the
  1044. LocalIdentity can install itself using this call. The function provided
  1045. in 'notifyProc' will be called whenever the requested event happens.
  1046. When an AuthLockLocalIdentity call is made to the toolbox, the notificationProc
  1047. will be called with 'kAuthLockPending'. The application may refuse the lock by returning
  1048. a 'true' value. If all the registered entries return 'false' value, locking will be done
  1049. successfully. Otherwise 'kOCEOperationDenied' error is returned to the caller. The appName
  1050. (registered with the notificationProc) of the application which denied locking is also
  1051. returned to the caller making the AuthLockIdentity call.
  1052. }
  1053.     AuthAddToLocalIdentityQueuePBPtr = ^AuthAddToLocalIdentityQueuePB;
  1054.     AuthAddToLocalIdentityQueuePB = RECORD
  1055.         qLink:                    Ptr;
  1056.         reserved1:                LONGINT;
  1057.         reserved2:                LONGINT;
  1058.         ioCompletion:            AuthIOCompletionUPP;
  1059.         ioResult:                OSErr;
  1060.         saveA5:                    UInt32;
  1061.         reqCode:                INTEGER;
  1062.         reserved:                ARRAY [0..1] OF LONGINT;
  1063.         serverHint:                AddrBlock;
  1064.         dsRefNum:                INTEGER;
  1065.         callID:                    UInt32;
  1066.         identity:                AuthIdentity;
  1067.         gReserved1:                LONGINT;
  1068.         gReserved2:                LONGINT;
  1069.         gReserved3:                LONGINT;
  1070.         clientData:                LONGINT;
  1071.         notifyProc:                NotificationUPP;                        {   --> notification procedure  }
  1072.         notifyFlags:            AuthNotifications;                        {   --> notifyFlags  }
  1073.         appName:                StringPtr;                                {   --> name of application to be returned in Delete/Stop  }
  1074.     END;
  1075.  
  1076. {
  1077. kAuthRemoveFromLocalIdentityQueue:}
  1078.     AuthRemoveFromLocalIdentityQueuePBPtr = ^AuthRemoveFromLocalIdentityQueuePB;
  1079.     AuthRemoveFromLocalIdentityQueuePB = RECORD
  1080.         qLink:                    Ptr;
  1081.         reserved1:                LONGINT;
  1082.         reserved2:                LONGINT;
  1083.         ioCompletion:            AuthIOCompletionUPP;
  1084.         ioResult:                OSErr;
  1085.         saveA5:                    UInt32;
  1086.         reqCode:                INTEGER;
  1087.         reserved:                ARRAY [0..1] OF LONGINT;
  1088.         serverHint:                AddrBlock;
  1089.         dsRefNum:                INTEGER;
  1090.         callID:                    UInt32;
  1091.         identity:                AuthIdentity;
  1092.         gReserved1:                LONGINT;
  1093.         gReserved2:                LONGINT;
  1094.         gReserved3:                LONGINT;
  1095.         clientData:                LONGINT;
  1096.         notifyProc:                NotificationUPP;                        {   --> notification procedure  }
  1097.     END;
  1098.  
  1099. {
  1100. kAuthSetupLocalIdentity:
  1101. The LocalIdentity can be Setup using this call.
  1102. The userName and password correspond to the LocalIdentity setup.
  1103. If a LocalIdentity Setup already exists 'kOCELocalIdentitySetupExists' error
  1104. will be returned.
  1105. }
  1106.     AuthSetupLocalIdentityPBPtr = ^AuthSetupLocalIdentityPB;
  1107.     AuthSetupLocalIdentityPB = RECORD
  1108.         qLink:                    Ptr;
  1109.         reserved1:                LONGINT;
  1110.         reserved2:                LONGINT;
  1111.         ioCompletion:            AuthIOCompletionUPP;
  1112.         ioResult:                OSErr;
  1113.         saveA5:                    UInt32;
  1114.         reqCode:                INTEGER;
  1115.         reserved:                ARRAY [0..1] OF LONGINT;
  1116.         serverHint:                AddrBlock;
  1117.         dsRefNum:                INTEGER;
  1118.         callID:                    UInt32;
  1119.         identity:                AuthIdentity;
  1120.         gReserved1:                LONGINT;
  1121.         gReserved2:                LONGINT;
  1122.         gReserved3:                LONGINT;
  1123.         clientData:                LONGINT;
  1124.         aReserved:                LONGINT;                                {   --   }
  1125.         userName:                RStringPtr;                                {   --> userName  }
  1126.         password:                RStringPtr;                                {   -->user password  }
  1127.     END;
  1128.  
  1129. {
  1130. kAuthChangeLocalIdentity:
  1131. An existing LocalIdentity  Setup can be changed using this call.
  1132. The userName and password correspond to the LocalIdentity setup.
  1133. If a LocalIdentity Setup does not exists 'kOCEOCESetupRequired' error
  1134. will be returned. The user can use  kAuthSetupLocalIdentity call to setit up.
  1135. If the 'password' does not correspond to the existing setup, 'kOCELocalAuthenticationFail'
  1136. OSErr will be returned. If successful, LocalID will have new name as 'userName' and
  1137. password as 'newPassword' and if any applications has installed into 
  1138. LocalIdentityQueue with kNotifyNameChangeMask set, it will be notified with 
  1139. kAuthLocalIdentityNameChangeOp action value. 
  1140.  
  1141. }
  1142.     AuthChangeLocalIdentityPBPtr = ^AuthChangeLocalIdentityPB;
  1143.     AuthChangeLocalIdentityPB = RECORD
  1144.         qLink:                    Ptr;
  1145.         reserved1:                LONGINT;
  1146.         reserved2:                LONGINT;
  1147.         ioCompletion:            AuthIOCompletionUPP;
  1148.         ioResult:                OSErr;
  1149.         saveA5:                    UInt32;
  1150.         reqCode:                INTEGER;
  1151.         reserved:                ARRAY [0..1] OF LONGINT;
  1152.         serverHint:                AddrBlock;
  1153.         dsRefNum:                INTEGER;
  1154.         callID:                    UInt32;
  1155.         identity:                AuthIdentity;
  1156.         gReserved1:                LONGINT;
  1157.         gReserved2:                LONGINT;
  1158.         gReserved3:                LONGINT;
  1159.         clientData:                LONGINT;
  1160.         aReserved:                LONGINT;                                {   --   }
  1161.         userName:                RStringPtr;                                {   --> userName  }
  1162.         password:                RStringPtr;                                {   --> current password  }
  1163.         newPassword:            RStringPtr;                                {   --> new password  }
  1164.     END;
  1165.  
  1166. {
  1167. kAuthRemoveLocalIdentity:
  1168. An existing LocalIdentity  Setup can be removed using this call.
  1169. The userName and password correspond to the LocalIdentity setup.
  1170. If a LocalIdentity Setup does not exists 'kOCEOCESetupRequired' error
  1171. will be returned.
  1172. If the 'password' does not correspond to the existing setup, 'kOCELocalAuthenticationFail'
  1173. OSErr will be returned. If successful, LocalIdentity will be removed from the OCE Setup.
  1174. This is a very distructive operation, user must be warned enough before actually making
  1175. this call.
  1176. }
  1177.     AuthRemoveLocalIdentityPBPtr = ^AuthRemoveLocalIdentityPB;
  1178.     AuthRemoveLocalIdentityPB = RECORD
  1179.         qLink:                    Ptr;
  1180.         reserved1:                LONGINT;
  1181.         reserved2:                LONGINT;
  1182.         ioCompletion:            AuthIOCompletionUPP;
  1183.         ioResult:                OSErr;
  1184.         saveA5:                    UInt32;
  1185.         reqCode:                INTEGER;
  1186.         reserved:                ARRAY [0..1] OF LONGINT;
  1187.         serverHint:                AddrBlock;
  1188.         dsRefNum:                INTEGER;
  1189.         callID:                    UInt32;
  1190.         identity:                AuthIdentity;
  1191.         gReserved1:                LONGINT;
  1192.         gReserved2:                LONGINT;
  1193.         gReserved3:                LONGINT;
  1194.         clientData:                LONGINT;
  1195.         aReserved:                LONGINT;                                {   --   }
  1196.         userName:                RStringPtr;                                {   --> userName  }
  1197.         password:                RStringPtr;                                {   --> current password  }
  1198.     END;
  1199.  
  1200. {
  1201. kOCESetupAddDirectoryInfo:
  1202. Using this call identity for a catalog can be setup under LocalIdentity umbrella.
  1203. ASCreateLocalIdentity should have been done succesfully before making this call.    
  1204. directoryRecordCID -> is the record creationID obtained when DirAddOCEDirectory or
  1205. DirAddDSAMDirectory call was made.
  1206. rid-> is the recordID in which the identity for the catalog will be established.
  1207. password-> the password associated with the rid in the catalog world.
  1208. }
  1209.     OCESetupAddDirectoryInfoPBPtr = ^OCESetupAddDirectoryInfoPB;
  1210.     OCESetupAddDirectoryInfoPB = RECORD
  1211.         qLink:                    Ptr;
  1212.         reserved1:                LONGINT;
  1213.         reserved2:                LONGINT;
  1214.         ioCompletion:            AuthIOCompletionUPP;
  1215.         ioResult:                OSErr;
  1216.         saveA5:                    UInt32;
  1217.         reqCode:                INTEGER;
  1218.         reserved:                ARRAY [0..1] OF LONGINT;
  1219.         serverHint:                AddrBlock;
  1220.         dsRefNum:                INTEGER;
  1221.         callID:                    UInt32;
  1222.         identity:                AuthIdentity;
  1223.         gReserved1:                LONGINT;
  1224.         gReserved2:                LONGINT;
  1225.         gReserved3:                LONGINT;
  1226.         clientData:                LONGINT;
  1227.         directoryRecordCID:        CreationID;                                {   --> CreationID for the catalog  }
  1228.         recordID:                RecordIDPtr;                            {   --> recordID for the identity  }
  1229.         password:                RStringPtr;                                {   --> password in the catalog world  }
  1230.     END;
  1231.  
  1232. {
  1233. kOCESetupChangeDirectoryInfo:
  1234. Using this call an existing identity for a catalog under LocalIdentity umbrella
  1235. can be changed.
  1236. ASCreateLocalIdentity should have been done succesfully before making this call.
  1237. directoryRecordCID -> is the record creationID obtained when DirAddOCEDirectory or
  1238. DirAddDSAMDirectory call was made.
  1239. rid-> is the recordID in which the identity for the catalog will be established.
  1240. password-> the password associated with the rid in the catalog world.
  1241. newPassword -> the new password for the catalog
  1242. }
  1243.     OCESetupChangeDirectoryInfoPBPtr = ^OCESetupChangeDirectoryInfoPB;
  1244.     OCESetupChangeDirectoryInfoPB = RECORD
  1245.         qLink:                    Ptr;
  1246.         reserved1:                LONGINT;
  1247.         reserved2:                LONGINT;
  1248.         ioCompletion:            AuthIOCompletionUPP;
  1249.         ioResult:                OSErr;
  1250.         saveA5:                    UInt32;
  1251.         reqCode:                INTEGER;
  1252.         reserved:                ARRAY [0..1] OF LONGINT;
  1253.         serverHint:                AddrBlock;
  1254.         dsRefNum:                INTEGER;
  1255.         callID:                    UInt32;
  1256.         identity:                AuthIdentity;
  1257.         gReserved1:                LONGINT;
  1258.         gReserved2:                LONGINT;
  1259.         gReserved3:                LONGINT;
  1260.         clientData:                LONGINT;
  1261.         directoryRecordCID:        CreationID;                                {   --> CreationID for the catalog  }
  1262.         recordID:                RecordIDPtr;                            {   --> recordID for the identity  }
  1263.         password:                RStringPtr;                                {   --> password in the catalog world  }
  1264.         newPassword:            RStringPtr;                                {   --> new password in the catalog  }
  1265.     END;
  1266.  
  1267. {
  1268. kOCESetupRemoveDirectoryInfo:
  1269. Using this call an existing identity for a catalog under LocalIdentity umbrella
  1270. can be changed.
  1271. ASCreateLocalIdentity should have been done succesfully before making this call.
  1272. directoryRecordCID -> is the record creationID obtained when DirAddOCEDirectory or
  1273. }
  1274.     OCESetupRemoveDirectoryInfoPBPtr = ^OCESetupRemoveDirectoryInfoPB;
  1275.     OCESetupRemoveDirectoryInfoPB = RECORD
  1276.         qLink:                    Ptr;
  1277.         reserved1:                LONGINT;
  1278.         reserved2:                LONGINT;
  1279.         ioCompletion:            AuthIOCompletionUPP;
  1280.         ioResult:                OSErr;
  1281.         saveA5:                    UInt32;
  1282.         reqCode:                INTEGER;
  1283.         reserved:                ARRAY [0..1] OF LONGINT;
  1284.         serverHint:                AddrBlock;
  1285.         dsRefNum:                INTEGER;
  1286.         callID:                    UInt32;
  1287.         identity:                AuthIdentity;
  1288.         gReserved1:                LONGINT;
  1289.         gReserved2:                LONGINT;
  1290.         gReserved3:                LONGINT;
  1291.         clientData:                LONGINT;
  1292.         directoryRecordCID:        CreationID;                                {   --> CreationID for the catalog  }
  1293.     END;
  1294.  
  1295. {
  1296. kOCESetupGetDirectoryInfo:
  1297. Using this call info on an existing identity for a particular catalog under LocalIdentity umbrella
  1298. can be obtained.
  1299. For the specified catalog 'directoryName' and 'discriminator', rid and nativeName will
  1300. returned. Caller must provide appropriate buffer to get back rid and nativeName.
  1301. 'password' will be returned  for  non-ADAP Catalogs.
  1302. }
  1303.     OCESetupGetDirectoryInfoPBPtr = ^OCESetupGetDirectoryInfoPB;
  1304.     OCESetupGetDirectoryInfoPB = RECORD
  1305.         qLink:                    Ptr;
  1306.         reserved1:                LONGINT;
  1307.         reserved2:                LONGINT;
  1308.         ioCompletion:            AuthIOCompletionUPP;
  1309.         ioResult:                OSErr;
  1310.         saveA5:                    UInt32;
  1311.         reqCode:                INTEGER;
  1312.         reserved:                ARRAY [0..1] OF LONGINT;
  1313.         serverHint:                AddrBlock;
  1314.         dsRefNum:                INTEGER;
  1315.         callID:                    UInt32;
  1316.         identity:                AuthIdentity;
  1317.         gReserved1:                LONGINT;
  1318.         gReserved2:                LONGINT;
  1319.         gReserved3:                LONGINT;
  1320.         clientData:                LONGINT;
  1321.         directoryName:            DirectoryNamePtr;                        {   --> catalog name  }
  1322.         discriminator:            DirDiscriminator;                        {   --> discriminator for the catalog  }
  1323.         recordID:                RecordIDPtr;                            {  <--  rid for the catalog identity  }
  1324.         nativeName:                RStringPtr;                                {  <--  user name in the catalog world  }
  1325.         password:                RStringPtr;                                {  <--  password in the catalog world  }
  1326.     END;
  1327.  
  1328. {****************************************************************************
  1329.  
  1330.  
  1331.          Catalog Manager operations
  1332.  
  1333.  
  1334. ****************************************************************************}
  1335.     DirParamBlockPtr = ^DirParamBlock;
  1336. {$IFC TYPED_FUNCTION_POINTERS}
  1337.     DirIOCompletionProcPtr = PROCEDURE(paramBlock: DirParamBlockPtr);
  1338. {$ELSEC}
  1339.     DirIOCompletionProcPtr = Register68kProcPtr;
  1340. {$ENDC}
  1341.  
  1342.     DirIOCompletionUPP = UniversalProcPtr;
  1343. { AddRecord }
  1344.     DirAddRecordPBPtr = ^DirAddRecordPB;
  1345.     DirAddRecordPB = RECORD
  1346.         qLink:                    Ptr;
  1347.         reserved1:                LONGINT;
  1348.         reserved2:                LONGINT;
  1349.         ioCompletion:            DirIOCompletionUPP;
  1350.         ioResult:                OSErr;
  1351.         saveA5:                    UInt32;
  1352.         reqCode:                INTEGER;
  1353.         reserved:                ARRAY [0..1] OF LONGINT;
  1354.         serverHint:                AddrBlock;
  1355.         dsRefNum:                INTEGER;
  1356.         callID:                    UInt32;
  1357.         identity:                AuthIdentity;
  1358.         gReserved1:                LONGINT;
  1359.         gReserved2:                LONGINT;
  1360.         gReserved3:                LONGINT;
  1361.         clientData:                LONGINT;
  1362.         aRecord:                RecordIDPtr;                            {   --> CreationID returned here  }
  1363.         allowDuplicate:            BOOLEAN;                                {   -->  }
  1364.         filler1:                BOOLEAN;
  1365.     END;
  1366.  
  1367.  
  1368.  
  1369. { DeleteRecord }
  1370.     DirDeleteRecordPBPtr = ^DirDeleteRecordPB;
  1371.     DirDeleteRecordPB = RECORD
  1372.         qLink:                    Ptr;
  1373.         reserved1:                LONGINT;
  1374.         reserved2:                LONGINT;
  1375.         ioCompletion:            DirIOCompletionUPP;
  1376.         ioResult:                OSErr;
  1377.         saveA5:                    UInt32;
  1378.         reqCode:                INTEGER;
  1379.         reserved:                ARRAY [0..1] OF LONGINT;
  1380.         serverHint:                AddrBlock;
  1381.         dsRefNum:                INTEGER;
  1382.         callID:                    UInt32;
  1383.         identity:                AuthIdentity;
  1384.         gReserved1:                LONGINT;
  1385.         gReserved2:                LONGINT;
  1386.         gReserved3:                LONGINT;
  1387.         clientData:                LONGINT;
  1388.         aRecord:                RecordIDPtr;                            {   -->  }
  1389.     END;
  1390.  
  1391. { aRecord must contain valid PackedRLI and a CreationID. }
  1392.  
  1393.  
  1394. {********************************************************************************}
  1395. {
  1396. DirEnumerate:
  1397. This call can be used to enumerate both DNodes and records under a specified
  1398. DNode. A DNode is specified by the PackedRLIPtr 'aRLI'.
  1399.  
  1400. startingPoint indicates where to start the enumeration.  Initially,
  1401. it should be set to a value of nil.  After some records are enumerated,
  1402. the client can issue the call again with the same aRLI and recordName and
  1403. typeList. The last received DirEnumSpec in the startingPoint field.  The server
  1404. will continue the enumeration from that record on. if user wants to get back the
  1405. value specified in the startingRecord also, the Boolean 'includeStartingPoint'
  1406. must be set to 'true'. If this is set to 'false', records specified after the
  1407. startingPoint record will be returned.
  1408.  
  1409. sortBy indicates to the server to return the records that match in name-first
  1410. or type-first order.  sortDirection indicates to the server to search in forward
  1411. or backward sort order for RecordIDs Specified.
  1412.  
  1413. RecordIDS and Enumeration Criteria:
  1414.  
  1415. PackedRLIPtr parameter 'aRLI' will be accepted for DNode
  1416. specification.
  1417.  
  1418. One RStringPtr 'nameMatchString' is provided. User is allowed to
  1419. specify a wild card in the name. WildCard specification is specified in 
  1420. matchNameHow parameter and possible values are defined in DirMatchWith Enum.
  1421.  
  1422. 'typeCount' parameter indicate how many types are in the 'typeList'.
  1423.  
  1424. 'typeList' parmeter is a pointer to an RString array of size 'typeCount'.
  1425.  
  1426. If 'typeCount' is exactly equal to one, a wild card can be specified
  1427. for the entity type; otherwise types have to be completely specified.
  1428. WildCard specification is specified in  matchNameHow parameter
  1429.  and possible values are defined in DirMatchWith Enum.
  1430.  
  1431.  
  1432. A nil value for 'startingPoint' is allowed when sortDirection specified
  1433. is 'kSortBackwards'. This was not allowed previously.
  1434.  
  1435. 'enumFlags' parameter is a bit field. The following bits can be set:
  1436.     kEnumDistinguishedNameMask to get back records in the cluster data base.
  1437.     kEnumAliasMask to get back record aliases
  1438.     kEnumPseudonymMask to get back record pseudonyms
  1439.     kEnumDNodeMask to get back any children dNodes for the DNode specified in the
  1440.     'aRLI' parameter.
  1441.     kEnumForeignDNodeMask to get back any children dNodes which have ForeignDnodes in the
  1442.     dNode specified in the 'aRLI' parameter.
  1443.  
  1444.     kEnumAll is combination of all five values and can be used to enumerate
  1445.     everything under a specified DNode.
  1446.  
  1447.  
  1448.  
  1449. The results returned for each element will consist of a DirEnumSpec.
  1450. The DirEnumSpec contains 'enumFlag' which indicates the type of entity and a
  1451. union which will have either DNodeID or LocalRecordID depending on the value of 'enumFlag'.
  1452. The 'enumFlag'  will indicate whether the returned element is a
  1453. record(kEnumDistinguishedNameMask bit) or a alias(kEnumAliasMask bit) or a
  1454. Pseudonym(kEnumPseudonymMask) or a child DNode(kEnumDNodeMask bit).  If the 'enumFlag' value
  1455. is kEnumDnodeMask, it indicates the value returned in the union is a DNodeID (i.e. 'dNodeNumber'
  1456. is the 'dNodeNumber' of the child dnode(if the catalog supports dNodeNumbers, otherwise
  1457. this will be set to zero). The name will be the child dnode name. For other values of the
  1458. 'enumFlag', the value in the union will be LocalRecordID. In addition to kEnumDnodeMask it is
  1459. possible that kEnumForeignDNodeMask is also set. This is an advisory bit and application must make
  1460. it's own decision before displaying these records. If catalog supports kSupportIndexRatioMask, it
  1461. may also return the relative position of the record (percentile of total records) in the 
  1462. indexRatio field in EnumSpec.
  1463.  
  1464.  
  1465. responseSLRV will contain the script, language, region and version of the oce sorting software.
  1466. The results will be collected in the 'getBuffer' supplied by the user.
  1467. If buffer can not hold all the data returned 'kOCEMoreData' error will be returned.
  1468.  
  1469. If user receives 'noErr' or 'kOCEMoreData', buffer will contain valid results. A user
  1470. can extract the results in the 'getBuffer' by making DirEnumerateParse' call.
  1471. }
  1472.  
  1473.     DirEnumerateGetPBPtr = ^DirEnumerateGetPB;
  1474.     DirEnumerateGetPB = RECORD
  1475.         qLink:                    Ptr;
  1476.         reserved1:                LONGINT;
  1477.         reserved2:                LONGINT;
  1478.         ioCompletion:            DirIOCompletionUPP;
  1479.         ioResult:                OSErr;
  1480.         saveA5:                    UInt32;
  1481.         reqCode:                INTEGER;
  1482.         reserved:                ARRAY [0..1] OF LONGINT;
  1483.         serverHint:                AddrBlock;
  1484.         dsRefNum:                INTEGER;
  1485.         callID:                    UInt32;
  1486.         identity:                AuthIdentity;
  1487.         gReserved1:                LONGINT;
  1488.         gReserved2:                LONGINT;
  1489.         gReserved3:                LONGINT;
  1490.         clientData:                LONGINT;
  1491.         aRLI:                    PackedRLIPtr;                            {   --> an RLI specifying the cluster to be enumerated  }
  1492.         startingPoint:            DirEnumSpecPtr;                            {   -->  }
  1493.         sortBy:                    DirSortOption;                            {   -->  }
  1494.         sortDirection:            DirSortDirection;                        {   -->  }
  1495.         dReserved:                LONGINT;                                {   --   }
  1496.         nameMatchString:        RStringPtr;                                {   --> name from which enumeration should start  }
  1497.         typesList:                ^RStringPtr;                            {   --> list of entity types to be enumerated  }
  1498.         typeCount:                UInt32;                                    {   --> number of types in the list  }
  1499.         enumFlags:                DirEnumChoices;                            {   --> indicates what to enumerate  }
  1500.         includeStartingPoint:    BOOLEAN;                                {   --> if true return the record specified in starting point  }
  1501.         padByte:                SInt8;
  1502.         matchNameHow:            SInt8;                                    {   --> Matching Criteria for nameMatchString  }
  1503.         matchTypeHow:            SInt8;                                    {   --> Matching Criteria for typeList  }
  1504.         getBuffer:                Ptr;                                    {   -->  }
  1505.         getBufferSize:            UInt32;                                    {   -->  }
  1506.         responseSLRV:            SLRV;                                    {   <--  response SLRV  }
  1507.     END;
  1508.  
  1509. { The EnumerateRecords call-back function is defined as follows: }
  1510. {$IFC TYPED_FUNCTION_POINTERS}
  1511.     ForEachDirEnumSpecProcPtr = FUNCTION(clientData: LONGINT; {CONST}VAR enumSpec: DirEnumSpec): BOOLEAN;
  1512. {$ELSEC}
  1513.     ForEachDirEnumSpecProcPtr = ProcPtr;
  1514. {$ENDC}
  1515.  
  1516.     ForEachDirEnumSpecUPP = UniversalProcPtr;
  1517.     ForEachDirEnumSpec                    = ForEachDirEnumSpecUPP;
  1518. {
  1519. EnumerateParse:
  1520. After an EnumerateGet call has completed, call EnumerateParse
  1521. to parse through the buffer that was filled in EnumerateGet.
  1522.  
  1523. 'eachEnumSpec' will be called each time to return to the client a
  1524. DirEnumSpec that matches the pattern for enumeration. 'enumFlag' indicates the type
  1525. of information returned in the DirEnumSpec
  1526. The clientData parameter that you pass in the parameter block will be passed
  1527. to 'forEachEnumDSSpecFunc'.  You are free to put anything in clientData - it is intended
  1528. to allow you some way to match the call-back to the original call (for
  1529. example, you make more then one aysynchronous EnumerateGet calls and you want to
  1530. associate returned results in some way).
  1531.  
  1532. The client should return FALSE from 'eachEnumSpec' to continue
  1533. processing of the EnumerateParse request.  Returning TRUE will
  1534. terminate the EnumerateParse request.
  1535.  
  1536. For synchronous calls, the call-back routine actually runs as part of the same thread
  1537. of execution as the thread that made the EnumerateParse call.  That means that the
  1538. same low-memory globals, A5, stack, etc. are in effect during the call-back
  1539. that were in effect when the call was made.  Because of this, the call-back
  1540. routine has the same restrictions as the caller of EnumerateParse:
  1541. if EnumerateParse was not called from interrupt level, then the call-
  1542. back routine can allocate memory. For asynchronous calls, call-back routine is
  1543. like a ioCompletion except that A5 will be preserved for the application.
  1544. }
  1545.     DirEnumerateParsePBPtr = ^DirEnumerateParsePB;
  1546.     DirEnumerateParsePB = RECORD
  1547.         qLink:                    Ptr;
  1548.         reserved1:                LONGINT;
  1549.         reserved2:                LONGINT;
  1550.         ioCompletion:            DirIOCompletionUPP;
  1551.         ioResult:                OSErr;
  1552.         saveA5:                    UInt32;
  1553.         reqCode:                INTEGER;
  1554.         reserved:                ARRAY [0..1] OF LONGINT;
  1555.         serverHint:                AddrBlock;
  1556.         dsRefNum:                INTEGER;
  1557.         callID:                    UInt32;
  1558.         identity:                AuthIdentity;
  1559.         gReserved1:                LONGINT;
  1560.         gReserved2:                LONGINT;
  1561.         gReserved3:                LONGINT;
  1562.         clientData:                LONGINT;
  1563.         aRLI:                    PackedRLIPtr;                            {   --> an RLI specifying the cluster to be enumerated  }
  1564.         bReserved:                LONGINT;                                {   --   }
  1565.         cReserved:                LONGINT;                                {   --   }
  1566.         eachEnumSpec:            ForEachDirEnumSpec;                        {   -->  }
  1567.         eReserved:                LONGINT;                                {   --   }
  1568.         fReserved:                LONGINT;                                {   --   }
  1569.         gReserved:                LONGINT;                                {   --   }
  1570.         hReserved:                LONGINT;                                {   --   }
  1571.         iReserved:                LONGINT;                                {   --   }
  1572.         getBuffer:                Ptr;                                    {   -->  }
  1573.         getBufferSize:            UInt32;                                    {   -->  }
  1574.         l1Reserved:                INTEGER;                                {   --  }
  1575.         l2Reserved:                INTEGER;                                {   --   }
  1576.         l3Reserved:                INTEGER;                                {   --  }
  1577.         l4Reserved:                INTEGER;                                {   --   }
  1578.     END;
  1579.  
  1580. {
  1581.  * FindRecordGet operates similarly to DirEnumerate except it returns a list
  1582.  * of records instead of records local to a cluster.
  1583. }
  1584.     DirFindRecordGetPBPtr = ^DirFindRecordGetPB;
  1585.     DirFindRecordGetPB = RECORD
  1586.         qLink:                    Ptr;
  1587.         reserved1:                LONGINT;
  1588.         reserved2:                LONGINT;
  1589.         ioCompletion:            DirIOCompletionUPP;
  1590.         ioResult:                OSErr;
  1591.         saveA5:                    UInt32;
  1592.         reqCode:                INTEGER;
  1593.         reserved:                ARRAY [0..1] OF LONGINT;
  1594.         serverHint:                AddrBlock;
  1595.         dsRefNum:                INTEGER;
  1596.         callID:                    UInt32;
  1597.         identity:                AuthIdentity;
  1598.         gReserved1:                LONGINT;
  1599.         gReserved2:                LONGINT;
  1600.         gReserved3:                LONGINT;
  1601.         clientData:                LONGINT;
  1602.         startingPoint:            RecordIDPtr;
  1603.         reservedA:                ARRAY [0..1] OF LONGINT;
  1604.         nameMatchString:        RStringPtr;
  1605.         typesList:                ^RStringPtr;
  1606.         typeCount:                UInt32;
  1607.         reservedB:                LONGINT;
  1608.         reservedC:                INTEGER;
  1609.         matchNameHow:            SInt8;
  1610.         matchTypeHow:            SInt8;
  1611.         getBuffer:                Ptr;
  1612.         getBufferSize:            UInt32;
  1613.         directoryName:            DirectoryNamePtr;
  1614.         discriminator:            DirDiscriminator;
  1615.     END;
  1616.  
  1617. { The FindRecordParse call-back function is defined as follows: }
  1618. {$IFC TYPED_FUNCTION_POINTERS}
  1619.     ForEachRecordProcPtr = FUNCTION(clientData: LONGINT; {CONST}VAR enumSpec: DirEnumSpec; pRLI: PackedRLIPtr): BOOLEAN;
  1620. {$ELSEC}
  1621.     ForEachRecordProcPtr = ProcPtr;
  1622. {$ENDC}
  1623.  
  1624.     ForEachRecordUPP = UniversalProcPtr;
  1625.     ForEachRecord                        = ForEachRecordUPP;
  1626. {
  1627.  * This PB same as DirFindRecordGet except it includes the callback function
  1628. }
  1629.     DirFindRecordParsePBPtr = ^DirFindRecordParsePB;
  1630.     DirFindRecordParsePB = RECORD
  1631.         qLink:                    Ptr;
  1632.         reserved1:                LONGINT;
  1633.         reserved2:                LONGINT;
  1634.         ioCompletion:            DirIOCompletionUPP;
  1635.         ioResult:                OSErr;
  1636.         saveA5:                    UInt32;
  1637.         reqCode:                INTEGER;
  1638.         reserved:                ARRAY [0..1] OF LONGINT;
  1639.         serverHint:                AddrBlock;
  1640.         dsRefNum:                INTEGER;
  1641.         callID:                    UInt32;
  1642.         identity:                AuthIdentity;
  1643.         gReserved1:                LONGINT;
  1644.         gReserved2:                LONGINT;
  1645.         gReserved3:                LONGINT;
  1646.         clientData:                LONGINT;
  1647.         startingPoint:            RecordIDPtr;
  1648.         reservedA:                ARRAY [0..1] OF LONGINT;
  1649.         nameMatchString:        RStringPtr;
  1650.         typesList:                ^RStringPtr;
  1651.         typeCount:                UInt32;
  1652.         reservedB:                LONGINT;
  1653.         reservedC:                INTEGER;
  1654.         matchNameHow:            SInt8;
  1655.         matchTypeHow:            SInt8;
  1656.         getBuffer:                Ptr;
  1657.         getBufferSize:            UInt32;
  1658.         directoryName:            DirectoryNamePtr;
  1659.         discriminator:            DirDiscriminator;
  1660.         forEachRecordFunc:        ForEachRecord;
  1661.     END;
  1662.  
  1663.  
  1664.  
  1665. {
  1666. LookupGet:
  1667.  
  1668. aRecordList is an array of pointers to RecordIDs, each of which must
  1669. contain valid PackedRLI and a CreationID.  recordIDCount is
  1670. the size of this array.
  1671.  
  1672. attrTypeList is an array of pointers to AttributeTypes.  attrTypeCount is
  1673. the size of this array.
  1674.  
  1675. staringRecordIndex is the record from which to continue the lookup.
  1676. If you want to start from first record in the list, this must be 1 (not zero).
  1677. This value must always be <= recordIDCount.
  1678.  
  1679. startingAttributeIndex is the AttributeType from which we want to continue the lookup.
  1680. If you want to start from first attribute in the list, this must be 1 (not zero).
  1681. This value must always be <= attrTypeCount.
  1682.  
  1683. startingAttribute is the value of the attribute value from which we want to
  1684. continue lookup. In case of catalogs supporting creationIDs, startingAttribute
  1685. may contain only a CID. Other catalogs may require the entire value.
  1686. If a non-null cid is given and if an attribute value with that cid is not found, this
  1687. call will terminate with kOCENoSuchAttribute error. A client should not make a LookupParse call
  1688. after getting this error.
  1689.  
  1690. 'includeStartingPoint' boolean can be set to 'true' to receive the value specified in the
  1691. startingPoint in the results returned. If this is set to 'false', the value
  1692. specified in the startingAttribute will not be returned.
  1693.  
  1694. When LookupGet call fails with kOCEMoreData, the client will be able to find out where the call ended
  1695. with a subsequent LookupParse call. When the LookupParse call completes with kOCEMoreData,
  1696. lastRecordIndex, lastAttributeIndex and lastValueCID will point to the corresponding
  1697. recordID, attributeType and the CreationID of the last value returned successfully. These parameters
  1698. are exactly the same ones for the startingRecordIndex, startingAttributeIndex, and startingAttrValueCID
  1699. so they can be used in a subsequent LookupGet call to continue the lookup.
  1700.  
  1701. In an extreme case, It is possible that we had an attribute value that is too large to fit
  1702. in the client's buffer. In such cases, if it was the only thing that we tried to fit
  1703. into the buffer, the client will not able to proceed further because he will not know the
  1704. attributeCID of the attribute to continue with.  Also he does not know how big a buffer
  1705. would be needed for the next call to get this 'mondo' attribute value successfully.
  1706.  
  1707. to support this, LookupParse call will do the following:
  1708.  
  1709. If LookupGet has failed with kOCEMoreData error, LookupParse will check to make sure that
  1710. ForEachAttributeValueFunc has been called at least once. If so, the client has the option
  1711. to continue from that attribute CreationID (for PAB/ADAP) in the next LookupGet call.
  1712. However, if it was not even called once, then the attribute value may be too big to fit in the
  1713. user's buffer. In this case, lastAttrValueCID (lastAttribute) and attrSize are returned in the
  1714. parse buffer and the call will fail with kOCEMoreAttrValue. However, it is possible that
  1715. ForEachAttributeValue was not called because the user does not have read access to some of
  1716. the attributeTypes in the list, and the buffer was full before even reading the creationID of
  1717. any of the attribute values.  A kOCEMoreData error is returned.
  1718.  
  1719. The Toolbox will check for duplicate RecordIDs in the aRecordList. If found, it will return
  1720. 'daDuplicateRecordIDErr'.
  1721.  
  1722. The Toolbox will check for duplicate AttributeTypes in the attrTypeList. If found it will
  1723. return 'daDuplicateAttrTypeErr'.
  1724. }
  1725.     DirLookupGetPBPtr = ^DirLookupGetPB;
  1726.     DirLookupGetPB = RECORD
  1727.         qLink:                    Ptr;
  1728.         reserved1:                LONGINT;
  1729.         reserved2:                LONGINT;
  1730.         ioCompletion:            DirIOCompletionUPP;
  1731.         ioResult:                OSErr;
  1732.         saveA5:                    UInt32;
  1733.         reqCode:                INTEGER;
  1734.         reserved:                ARRAY [0..1] OF LONGINT;
  1735.         serverHint:                AddrBlock;
  1736.         dsRefNum:                INTEGER;
  1737.         callID:                    UInt32;
  1738.         identity:                AuthIdentity;
  1739.         gReserved1:                LONGINT;
  1740.         gReserved2:                LONGINT;
  1741.         gReserved3:                LONGINT;
  1742.         clientData:                LONGINT;
  1743.         aRecordList:            ^RecordIDPtr;                            {   --> an array of RecordID pointers  }
  1744.         attrTypeList:            ^AttributeTypePtr;                        {   --> an array of attribute types  }
  1745.         cReserved:                LONGINT;                                {   --   }
  1746.         dReserved:                LONGINT;                                {   --   }
  1747.         eReserved:                LONGINT;                                {   --   }
  1748.         fReserved:                LONGINT;                                {   --   }
  1749.         recordIDCount:            UInt32;                                    {   -->  }
  1750.         attrTypeCount:            UInt32;                                    {   -->  }
  1751.         includeStartingPoint:    BOOLEAN;                                {   --> if true return the value specified by the starting indices  }
  1752.         padByte:                SInt8;
  1753.         i1Reserved:                INTEGER;                                {   --   }
  1754.         getBuffer:                Ptr;                                    {   -->  }
  1755.         getBufferSize:            UInt32;                                    {   -->  }
  1756.         startingRecordIndex:    UInt32;                                    {   --> start from this record  }
  1757.         startingAttrTypeIndex:    UInt32;                                    {   --> start from this attribute type  }
  1758.         startingAttribute:        Attribute;                                {   --> start from this attribute value  }
  1759.         pReserved:                LONGINT;                                {   --   }
  1760.     END;
  1761.  
  1762. { The Lookup call-back functions are defined as follows: }
  1763. {$IFC TYPED_FUNCTION_POINTERS}
  1764.     ForEachLookupRecordIDProcPtr = FUNCTION(clientData: LONGINT; {CONST}VAR recordID: RecordID): BOOLEAN;
  1765. {$ELSEC}
  1766.     ForEachLookupRecordIDProcPtr = ProcPtr;
  1767. {$ENDC}
  1768.  
  1769.     ForEachLookupRecordIDUPP = UniversalProcPtr;
  1770.     ForEachLookupRecordID                = ForEachLookupRecordIDUPP;
  1771. {$IFC TYPED_FUNCTION_POINTERS}
  1772.     ForEachAttrTypeLookupProcPtr = FUNCTION(clientData: LONGINT; {CONST}VAR attrType: AttributeType; myAttrAccMask: AccessMask): BOOLEAN;
  1773. {$ELSEC}
  1774.     ForEachAttrTypeLookupProcPtr = ProcPtr;
  1775. {$ENDC}
  1776.  
  1777.     ForEachAttrTypeLookupUPP = UniversalProcPtr;
  1778.     ForEachAttrTypeLookup                = ForEachAttrTypeLookupUPP;
  1779. {$IFC TYPED_FUNCTION_POINTERS}
  1780.     ForEachAttrValueProcPtr = FUNCTION(clientData: LONGINT; {CONST}VAR attribute: Attribute): BOOLEAN;
  1781. {$ELSEC}
  1782.     ForEachAttrValueProcPtr = ProcPtr;
  1783. {$ENDC}
  1784.  
  1785.     ForEachAttrValueUPP = UniversalProcPtr;
  1786.     ForEachAttrValue                    = ForEachAttrValueUPP;
  1787. {
  1788. LookupParse:
  1789.  
  1790. After a LookupGet call has completed, call LookupParse
  1791. to parse through the buffer that was filled in LookupGet.  The
  1792. toolbox will parse through the buffer and call the appropriate call-back routines
  1793. for each item in the getBuffer.
  1794.  
  1795. 'eachRecordID' will be called each time to return to the client one of the
  1796. RecordIDs from aRecordList.  The clientData parameter that you
  1797. pass in the parameter block will be passed to eachRecordID.
  1798. You are free to put anything in clientData - it is intended to allow
  1799. you some way to match the call-back to the original call (in case, for
  1800. example, you make simultaneous asynchronous LookupGet calls).  If you don't
  1801. want to get a call-back for each RecordID (for example, if you're looking up
  1802. attributes for only one RecordID), pass nil for eachRecordID.
  1803.  
  1804. After forEachLocalRecordIDFunc is called, eachAttrType may be called to pass an
  1805. attribute type (one from attrTypeList) that exists in the record specified
  1806. in the last eachRecordID call.  If you don't want to get a call-back for
  1807. each AttributeType (for example, if you're looking up only one attribute type,
  1808. or you prefer to read the type from the Attribute struct during the eachAttrValue
  1809. call-back routine), pass nil for eachAttrType. However access controls may
  1810. prohibit you from reading some attribute types; in that case eachAttrValue
  1811. may not be called even though the value exists. Hence the client should
  1812. supply this call-back function to see the access controls for each attribute type.
  1813.  
  1814. This will be followed by one or more calls to eachAttrValue, to pass the
  1815. type, tag, and attribute value.  NOTE THIS CHANGE:  you are no longer expected to
  1816. pass a pointer to a buffer in which to put the value.  Now you get a pointer to
  1817. the value, and you can process it within the call-back routine.
  1818. After one or more values are returned, eachAttrType may be called again to pass
  1819. another attribute type that exists in the last-specified RecordID.
  1820.  
  1821. The client should return FALSE from eachRecordID, eachAttrType, and
  1822. eachAttrValue to continue processing of the LookupParse request.  Returning TRUE
  1823. from any call-back will terminate the LookupParse request.
  1824.  
  1825. If LookupGet has failed with kOCEMoreData error, LookupParse will check to make sure that
  1826. ForEachAttributeValueFunc has been called at least once. If so, the client has the option
  1827. to continue from that attribute CreationID (for PAB/ADAP) in the next LookupGet call.
  1828. However, if it was not even called once, then the attribute value may be too big to fit in the
  1829. user's buffer. In this case, lastAttrValueCID (lastAttribute) and attrSize are returned in the
  1830. parse buffer and the call will fail with kOCEMoreAttrValue. However, it is possible that
  1831. ForEachAttributeValue was not called because the user does not have read access to some of
  1832. the attributeTypes in the list, and the buffer was full before even reading the creationID of
  1833. any of the attribute values.  A kOCEMoreData error is returned.
  1834.  
  1835. For synchronous calls, the call-back routine actually runs as part of the same thread
  1836. of execution as the thread that made the LookupParse call.  That means that the
  1837. same low-memory globals, A5, stack, etc. are in effect during the call-back
  1838. that were in effect when the call was made.  Because of this, the call-back
  1839. routine has the same restrictions as the caller of LookupParse:
  1840. if LookupParse was not called from interrupt level, then the call-
  1841. back routine can allocate memory. For asynchronous calls, call-back routine is
  1842. like a ioCompletion except that A5 will be preserved for the application.
  1843. }
  1844.     DirLookupParsePBPtr = ^DirLookupParsePB;
  1845.     DirLookupParsePB = RECORD
  1846.         qLink:                    Ptr;
  1847.         reserved1:                LONGINT;
  1848.         reserved2:                LONGINT;
  1849.         ioCompletion:            DirIOCompletionUPP;
  1850.         ioResult:                OSErr;
  1851.         saveA5:                    UInt32;
  1852.         reqCode:                INTEGER;
  1853.         reserved:                ARRAY [0..1] OF LONGINT;
  1854.         serverHint:                AddrBlock;
  1855.         dsRefNum:                INTEGER;
  1856.         callID:                    UInt32;
  1857.         identity:                AuthIdentity;
  1858.         gReserved1:                LONGINT;
  1859.         gReserved2:                LONGINT;
  1860.         gReserved3:                LONGINT;
  1861.         clientData:                LONGINT;
  1862.         aRecordList:            ^RecordIDPtr;                            {   --> must be same from the corresponding Get call  }
  1863.         attrTypeList:            ^AttributeTypePtr;                        {   --> must be same from the corresponding Get call  }
  1864.         cReserved:                LONGINT;                                {   --   }
  1865.         eachRecordID:            ForEachLookupRecordID;                    {   -->  }
  1866.         eachAttrType:            ForEachAttrTypeLookup;                    {   -->  }
  1867.         eachAttrValue:            ForEachAttrValue;                        {   -->  }
  1868.         recordIDCount:            UInt32;                                    {   --> must be same from the corresponding Get call  }
  1869.         attrTypeCount:            UInt32;                                    {   --> must be same from the corresponding Get call  }
  1870.         iReserved:                LONGINT;                                {   --   }
  1871.         getBuffer:                Ptr;                                    {   --> must be same from the corresponding Get call }
  1872.         getBufferSize:            UInt32;                                    {   --> must be same from the corresponding Get call }
  1873.         lastRecordIndex:        UInt32;                                    {  <--  last RecordID processed when parse completed  }
  1874.         lastAttributeIndex:        UInt32;                                    {  <--  last Attribute Type processed when parse completed  }
  1875.         lastAttribute:            Attribute;                                {  <--  last attribute value (with this CreationID) processed when parse completed  }
  1876.         attrSize:                UInt32;                                    {  <--  length of the attribute we did not return  }
  1877.     END;
  1878.  
  1879.  
  1880.  
  1881. { AddAttributeValue }
  1882.     DirAddAttributeValuePBPtr = ^DirAddAttributeValuePB;
  1883.     DirAddAttributeValuePB = RECORD
  1884.         qLink:                    Ptr;
  1885.         reserved1:                LONGINT;
  1886.         reserved2:                LONGINT;
  1887.         ioCompletion:            DirIOCompletionUPP;
  1888.         ioResult:                OSErr;
  1889.         saveA5:                    UInt32;
  1890.         reqCode:                INTEGER;
  1891.         reserved:                ARRAY [0..1] OF LONGINT;
  1892.         serverHint:                AddrBlock;
  1893.         dsRefNum:                INTEGER;
  1894.         callID:                    UInt32;
  1895.         identity:                AuthIdentity;
  1896.         gReserved1:                LONGINT;
  1897.         gReserved2:                LONGINT;
  1898.         gReserved3:                LONGINT;
  1899.         clientData:                LONGINT;
  1900.         aRecord:                RecordIDPtr;                            {   -->  }
  1901.         attr:                    AttributePtr;                            {   --> AttributeCreationID returned here  }
  1902.     END;
  1903.  
  1904. {
  1905. aRecord must contain valid PackedRLI and a CreationID.
  1906.  
  1907. Instead of passing type, length, and value in three separate
  1908. fields, we take a pointer to an Attribute structure that contains
  1909. all three, and has room for the AttributeCreationNumber.
  1910. The AttributeCreationID will be returned in the attr itself.
  1911.  
  1912. The AttributeTag tells the catalog service that the attribute is an RString,
  1913. binary, or a RecordID.
  1914. }
  1915. {
  1916. DeleteAttributeType:
  1917. This call is provided so that an existing AttributeType can be deleted.
  1918. If any attribute values exist for this type, they will all be deleted
  1919. (if the user has access rights to delete the values) and then the attribute type
  1920. will be deleted. Otherwise dsAccessDenied error will be returned.
  1921. }
  1922.     DirDeleteAttributeTypePBPtr = ^DirDeleteAttributeTypePB;
  1923.     DirDeleteAttributeTypePB = RECORD
  1924.         qLink:                    Ptr;
  1925.         reserved1:                LONGINT;
  1926.         reserved2:                LONGINT;
  1927.         ioCompletion:            DirIOCompletionUPP;
  1928.         ioResult:                OSErr;
  1929.         saveA5:                    UInt32;
  1930.         reqCode:                INTEGER;
  1931.         reserved:                ARRAY [0..1] OF LONGINT;
  1932.         serverHint:                AddrBlock;
  1933.         dsRefNum:                INTEGER;
  1934.         callID:                    UInt32;
  1935.         identity:                AuthIdentity;
  1936.         gReserved1:                LONGINT;
  1937.         gReserved2:                LONGINT;
  1938.         gReserved3:                LONGINT;
  1939.         clientData:                LONGINT;
  1940.         aRecord:                RecordIDPtr;                            {   -->  }
  1941.         attrType:                AttributeTypePtr;                        {   -->  }
  1942.     END;
  1943.  
  1944. {
  1945.     DeleteAttributeValue
  1946. }
  1947.     DirDeleteAttributeValuePBPtr = ^DirDeleteAttributeValuePB;
  1948.     DirDeleteAttributeValuePB = RECORD
  1949.         qLink:                    Ptr;
  1950.         reserved1:                LONGINT;
  1951.         reserved2:                LONGINT;
  1952.         ioCompletion:            DirIOCompletionUPP;
  1953.         ioResult:                OSErr;
  1954.         saveA5:                    UInt32;
  1955.         reqCode:                INTEGER;
  1956.         reserved:                ARRAY [0..1] OF LONGINT;
  1957.         serverHint:                AddrBlock;
  1958.         dsRefNum:                INTEGER;
  1959.         callID:                    UInt32;
  1960.         identity:                AuthIdentity;
  1961.         gReserved1:                LONGINT;
  1962.         gReserved2:                LONGINT;
  1963.         gReserved3:                LONGINT;
  1964.         clientData:                LONGINT;
  1965.         aRecord:                RecordIDPtr;                            {   ->  }
  1966.         attr:                    AttributePtr;                            {   ->  }
  1967.     END;
  1968.  
  1969.  
  1970.  
  1971. {
  1972.     ChangeAttributeValue:
  1973.     currentAttr ==> the attribute to be changed. For ADAS and PAB CreationID is
  1974.                     sufficient
  1975.     newAttr     ==> new value for the attribute. For ADAS and PAB 
  1976.                     CreationID field will be set when
  1977.                     the call succeesfully completes
  1978.     
  1979.     aRecord     ==> must contain valid PackedRecordLocationInfo and a CreationID.
  1980.  
  1981.  
  1982.     
  1983. }
  1984.     DirChangeAttributeValuePBPtr = ^DirChangeAttributeValuePB;
  1985.     DirChangeAttributeValuePB = RECORD
  1986.         qLink:                    Ptr;
  1987.         reserved1:                LONGINT;
  1988.         reserved2:                LONGINT;
  1989.         ioCompletion:            DirIOCompletionUPP;
  1990.         ioResult:                OSErr;
  1991.         saveA5:                    UInt32;
  1992.         reqCode:                INTEGER;
  1993.         reserved:                ARRAY [0..1] OF LONGINT;
  1994.         serverHint:                AddrBlock;
  1995.         dsRefNum:                INTEGER;
  1996.         callID:                    UInt32;
  1997.         identity:                AuthIdentity;
  1998.         gReserved1:                LONGINT;
  1999.         gReserved2:                LONGINT;
  2000.         gReserved3:                LONGINT;
  2001.         clientData:                LONGINT;
  2002.         aRecord:                RecordIDPtr;                            {   ->  }
  2003.         currentAttr:            AttributePtr;                            {   ->  }
  2004.         newAttr:                AttributePtr;                            {   ->  }
  2005.     END;
  2006.  
  2007.  
  2008. { VerifyAttributeValue }
  2009.     DirVerifyAttributeValuePBPtr = ^DirVerifyAttributeValuePB;
  2010.     DirVerifyAttributeValuePB = RECORD
  2011.         qLink:                    Ptr;
  2012.         reserved1:                LONGINT;
  2013.         reserved2:                LONGINT;
  2014.         ioCompletion:            DirIOCompletionUPP;
  2015.         ioResult:                OSErr;
  2016.         saveA5:                    UInt32;
  2017.         reqCode:                INTEGER;
  2018.         reserved:                ARRAY [0..1] OF LONGINT;
  2019.         serverHint:                AddrBlock;
  2020.         dsRefNum:                INTEGER;
  2021.         callID:                    UInt32;
  2022.         identity:                AuthIdentity;
  2023.         gReserved1:                LONGINT;
  2024.         gReserved2:                LONGINT;
  2025.         gReserved3:                LONGINT;
  2026.         clientData:                LONGINT;
  2027.         aRecord:                RecordIDPtr;                            {   -->  }
  2028.         attr:                    AttributePtr;                            {   -->  }
  2029.     END;
  2030.  
  2031. {
  2032. aRecord must contain valid PackedRLI and a CreationID.
  2033.  
  2034. The attribute type and value are passed in the attribute structure.  If the
  2035. attribute CreationID is non-zero, the server will verify that an attribute with
  2036. the specified value and creation number exists in aRecord.  If the attribute
  2037. CreationID is zero, the server will verify the attribute by type and value
  2038. alone, and return the attribute CreationID in the Attribute struct if the
  2039. attribute exists.
  2040. }
  2041.  
  2042. {
  2043. EnumerateAttributeTypesGet:
  2044. The following two calls can be used to enumerate the attribute types present in
  2045. a specified RecordID.  The first, EnumerateAttributeTypesGet, processes the request
  2046. and reads the response into getBuffer, as much as will fit.  A kOCEMoreData error will
  2047. be returned if the buffer was not large enough.  After this call completes, the
  2048. client can call EnumerateAttributeTypesParse (see below).
  2049.  
  2050. The user will able to continue from a startingPoint by setting a startingAttrType.
  2051. Typically, this should be the last value returned in EnumerateAttributeTypesParse call
  2052. when 'kOCEMoreData' is returned.
  2053.  
  2054. If 'includeStartingPoint' is true when a 'startingAttrType' is specified, the starting value
  2055. will be included in the results, if it exists. If this is set to false, this value will not
  2056. be included. AttributeTypes following this type will be returned.
  2057. }
  2058.     DirEnumerateAttributeTypesGetPBPtr = ^DirEnumerateAttributeTypesGetPB;
  2059.     DirEnumerateAttributeTypesGetPB = RECORD
  2060.         qLink:                    Ptr;
  2061.         reserved1:                LONGINT;
  2062.         reserved2:                LONGINT;
  2063.         ioCompletion:            DirIOCompletionUPP;
  2064.         ioResult:                OSErr;
  2065.         saveA5:                    UInt32;
  2066.         reqCode:                INTEGER;
  2067.         reserved:                ARRAY [0..1] OF LONGINT;
  2068.         serverHint:                AddrBlock;
  2069.         dsRefNum:                INTEGER;
  2070.         callID:                    UInt32;
  2071.         identity:                AuthIdentity;
  2072.         gReserved1:                LONGINT;
  2073.         gReserved2:                LONGINT;
  2074.         gReserved3:                LONGINT;
  2075.         clientData:                LONGINT;
  2076.         aRecord:                RecordIDPtr;                            {   -->  }
  2077.         startingAttrType:        AttributeTypePtr;                        {   --> starting point  }
  2078.         cReserved:                LONGINT;                                {   --   }
  2079.         dReserved:                LONGINT;                                {   --   }
  2080.         eReserved:                LONGINT;                                {   --   }
  2081.         fReserved:                LONGINT;                                {   --   }
  2082.         gReserved:                LONGINT;                                {   --   }
  2083.         hReserved:                LONGINT;                                {   --   }
  2084.         includeStartingPoint:    BOOLEAN;                                {   --> if true return the attrType specified by starting point  }
  2085.         padByte:                SInt8;
  2086.         i1Reserved:                INTEGER;                                {   --   }
  2087.         getBuffer:                Ptr;                                    {   -->  }
  2088.         getBufferSize:            UInt32;                                    {   -->  }
  2089.     END;
  2090.  
  2091. { The call-back function is defined as follows: }
  2092. {$IFC TYPED_FUNCTION_POINTERS}
  2093.     ForEachAttrTypeProcPtr = FUNCTION(clientData: LONGINT; {CONST}VAR attrType: AttributeType): BOOLEAN;
  2094. {$ELSEC}
  2095.     ForEachAttrTypeProcPtr = ProcPtr;
  2096. {$ENDC}
  2097.  
  2098.     ForEachAttrTypeUPP = UniversalProcPtr;
  2099.     ForEachAttrType                        = ForEachAttrTypeUPP;
  2100. {
  2101. EnumerateAttributeTypesParse:
  2102. After an EnumerateAttributeTypesGet call has completed, call EnumerateAttributeTypesParse
  2103. to parse through the buffer that was filled in EnumerateAttributeTypesGet.  The
  2104. toolbox will parse through the buffer and call the call-back routine for
  2105. each attribute type in the getBuffer.
  2106.  
  2107. The client should return false from eachAttrType to continue
  2108. processing of the EnumerateAttributeTypesParse request.  Returning true will
  2109. terminate the EnumerateAttributeTypesParse request.  The clientData parameter that
  2110. you pass in the parameter block will be passed to eachAttrType.
  2111. You are free to put anything in clientData - it is intended to allow
  2112. you some way to match the call-back to the original call (in case, for
  2113. example, you make simultaneous asynchronous calls).
  2114.  
  2115. For synchronous calls, the call-back routine actually runs as part of the same thread
  2116. of execution as the thread that made the EnumerateAttributeTypesParse call.  That means that the
  2117. same low-memory globals, A5, stack, etc. are in effect during the call-back
  2118. that were in effect when the call was made.  Because of this, the call-back
  2119. routine has the same restrictions as the caller of EnumerateAttributeTypesParse.
  2120. If EnumerateAttributeTypesParse was not called from interrupt level, then the call-
  2121. back routine can allocate memory. For asynchronous calls, call-back routine is
  2122. like a ioCompletion except that A5 will be preserved for the application.
  2123. }
  2124.     DirEnumerateAttributeTypesParsePBPtr = ^DirEnumerateAttributeTypesParsePB;
  2125.     DirEnumerateAttributeTypesParsePB = RECORD
  2126.         qLink:                    Ptr;
  2127.         reserved1:                LONGINT;
  2128.         reserved2:                LONGINT;
  2129.         ioCompletion:            DirIOCompletionUPP;
  2130.         ioResult:                OSErr;
  2131.         saveA5:                    UInt32;
  2132.         reqCode:                INTEGER;
  2133.         reserved:                ARRAY [0..1] OF LONGINT;
  2134.         serverHint:                AddrBlock;
  2135.         dsRefNum:                INTEGER;
  2136.         callID:                    UInt32;
  2137.         identity:                AuthIdentity;
  2138.         gReserved1:                LONGINT;
  2139.         gReserved2:                LONGINT;
  2140.         gReserved3:                LONGINT;
  2141.         clientData:                LONGINT;
  2142.         aRecord:                RecordIDPtr;                            {   --> Same as DirEnumerateAttributeTypesGetPB  }
  2143.         bReserved:                LONGINT;                                {   --   }
  2144.         cReserved:                LONGINT;                                {   --   }
  2145.         dReserved:                LONGINT;                                {   --   }
  2146.         eachAttrType:            ForEachAttrType;                        {   -->  }
  2147.         fReserved:                LONGINT;                                {   --   }
  2148.         gReserved:                LONGINT;                                {   --   }
  2149.         hReserved:                LONGINT;                                {   --   }
  2150.         iReserved:                LONGINT;                                {   --   }
  2151.         getBuffer:                Ptr;                                    {   -->  }
  2152.         getBufferSize:            UInt32;                                    {   -->  }
  2153.     END;
  2154.  
  2155. {
  2156. DirAbort:
  2157. With this call a user will able to abort an outstanding catalog service call.
  2158. A user must pass a pointer to the parameter block for the outstanding call.
  2159. In the current version of the product, the toolbox will process this call
  2160. for NetSearchADAPDirectoriesGet or FindADAPDirectoryByNetSearch calls and if possible
  2161. it will abort. For other calls for ADAP and PAB this will return 'daAbortFailErr'.
  2162. For CSAM catalogs, this call will be passed to the corresponding CSAM driver.
  2163. The CSAM driver may process this call or may return 'daAbortFailErr'. This call can
  2164. be called only in synchronous mode. Since the abort call makes references to fields in
  2165. the pb associated with the original call, this pb must not be disposed or or altered if
  2166. the original call completes before the abort call has completed.
  2167. }
  2168.     DirAbortPBPtr = ^DirAbortPB;
  2169.     DirAbortPB = RECORD
  2170.         qLink:                    Ptr;
  2171.         reserved1:                LONGINT;
  2172.         reserved2:                LONGINT;
  2173.         ioCompletion:            DirIOCompletionUPP;
  2174.         ioResult:                OSErr;
  2175.         saveA5:                    UInt32;
  2176.         reqCode:                INTEGER;
  2177.         reserved:                ARRAY [0..1] OF LONGINT;
  2178.         serverHint:                AddrBlock;
  2179.         dsRefNum:                INTEGER;
  2180.         callID:                    UInt32;
  2181.         identity:                AuthIdentity;
  2182.         gReserved1:                LONGINT;
  2183.         gReserved2:                LONGINT;
  2184.         gReserved3:                LONGINT;
  2185.         clientData:                LONGINT;
  2186.         pb:                        DirParamBlockPtr;                        {   --> pb for the call which must be aborted  }
  2187.     END;
  2188.  
  2189.  
  2190. {
  2191. AddPseudonym:
  2192. An alternate name and type can be added to a given record. If allowDuplicate
  2193. is set the name and type will be added even if the same name and type already
  2194. exists.
  2195. }
  2196.     DirAddPseudonymPBPtr = ^DirAddPseudonymPB;
  2197.     DirAddPseudonymPB = RECORD
  2198.         qLink:                    Ptr;
  2199.         reserved1:                LONGINT;
  2200.         reserved2:                LONGINT;
  2201.         ioCompletion:            DirIOCompletionUPP;
  2202.         ioResult:                OSErr;
  2203.         saveA5:                    UInt32;
  2204.         reqCode:                INTEGER;
  2205.         reserved:                ARRAY [0..1] OF LONGINT;
  2206.         serverHint:                AddrBlock;
  2207.         dsRefNum:                INTEGER;
  2208.         callID:                    UInt32;
  2209.         identity:                AuthIdentity;
  2210.         gReserved1:                LONGINT;
  2211.         gReserved2:                LONGINT;
  2212.         gReserved3:                LONGINT;
  2213.         clientData:                LONGINT;
  2214.         aRecord:                RecordIDPtr;                            {   --> RecordID to which pseudonym is to be added  }
  2215.         pseudonymName:            RStringPtr;                                {   --> new name to be added as pseudonym  }
  2216.         pseudonymType:            RStringPtr;                                {   --> new name to be added as pseudonym  }
  2217.         allowDuplicate:            BOOLEAN;                                {   -->  }
  2218.         filler1:                BOOLEAN;
  2219.     END;
  2220.  
  2221. {
  2222. DeletePseudonym:
  2223. An alternate name and type for a given record can be deleted.
  2224. }
  2225.     DirDeletePseudonymPBPtr = ^DirDeletePseudonymPB;
  2226.     DirDeletePseudonymPB = RECORD
  2227.         qLink:                    Ptr;
  2228.         reserved1:                LONGINT;
  2229.         reserved2:                LONGINT;
  2230.         ioCompletion:            DirIOCompletionUPP;
  2231.         ioResult:                OSErr;
  2232.         saveA5:                    UInt32;
  2233.         reqCode:                INTEGER;
  2234.         reserved:                ARRAY [0..1] OF LONGINT;
  2235.         serverHint:                AddrBlock;
  2236.         dsRefNum:                INTEGER;
  2237.         callID:                    UInt32;
  2238.         identity:                AuthIdentity;
  2239.         gReserved1:                LONGINT;
  2240.         gReserved2:                LONGINT;
  2241.         gReserved3:                LONGINT;
  2242.         clientData:                LONGINT;
  2243.         aRecord:                RecordIDPtr;                            {   --> RecordID to which pseudonym to be added  }
  2244.         pseudonymName:            RStringPtr;                                {   --> pseudonymName to be deleted  }
  2245.         pseudonymType:            RStringPtr;                                {   --> pseudonymType to be deleted  }
  2246.     END;
  2247.  
  2248.  
  2249. {
  2250.     AddAlias:
  2251.     This call can be used to create an alias  record. The alias
  2252.     can be created either in the same or different cluster. ADAS will not support
  2253.     this call for this release. A new catalog capability flag 'kSupportsAlias' will indicate
  2254.     if the catalog supports this call. PAB's will support this call. For the PAB implementation,
  2255.     this call will create a record with the name and type specified an aRecord.
  2256.     This call works exactly like AddRecord.
  2257.     If 'allowDuplicate' is false and another record with same name and type already exists
  2258.     'daNoDupAllowed' error will be returned.
  2259. }
  2260.     DirAddAliasPBPtr = ^DirAddAliasPB;
  2261.     DirAddAliasPB = RECORD
  2262.         qLink:                    Ptr;
  2263.         reserved1:                LONGINT;
  2264.         reserved2:                LONGINT;
  2265.         ioCompletion:            DirIOCompletionUPP;
  2266.         ioResult:                OSErr;
  2267.         saveA5:                    UInt32;
  2268.         reqCode:                INTEGER;
  2269.         reserved:                ARRAY [0..1] OF LONGINT;
  2270.         serverHint:                AddrBlock;
  2271.         dsRefNum:                INTEGER;
  2272.         callID:                    UInt32;
  2273.         identity:                AuthIdentity;
  2274.         gReserved1:                LONGINT;
  2275.         gReserved2:                LONGINT;
  2276.         gReserved3:                LONGINT;
  2277.         clientData:                LONGINT;
  2278.         aRecord:                RecordIDPtr;                            {   ->  }
  2279.         allowDuplicate:            BOOLEAN;                                {   ->  }
  2280.         filler1:                BOOLEAN;
  2281.     END;
  2282.  
  2283. {
  2284. DirFindValue:
  2285. This call can be used to find the occurrence of a value. The value
  2286. to be matched is passed in the buffer 'matchingData' field. The current
  2287. ADAP/PAB implementation will match a maximum of 32 bytes of data.
  2288. For attribute values in the PAB/ADAP implementation, only the first 32 bytes will
  2289. be used for comparing the occurrence of data. Search can be restricted to
  2290. a particular record and/or attribute type by specifying 'aRecord' or 'aType'.
  2291. After finding one occurrence, 'startingRecord' and 'startingAttribute'
  2292. can be specified to find the next occurrence of the same value.
  2293. 'sortDirection' can be specified with starting values to search forward or backward.
  2294. When a matching value is found, the 'recordFound' indicates the reccordID in which the
  2295. data occurrence was found, 'attributeFound' indicates the attribute with in which the
  2296. matching data was found. ADAP/PAB implementation returns only the type and creationID of
  2297. attributes. Catalogs which don't support creationIDs may return the
  2298. complete value; hence this call may need a buffer to hold the data. For ADAP/PAB implementations
  2299. the user has to make a DirLookup call to get the actual data. 'recordFound' and
  2300. 'attributeFound' can be used to initialize 'startingRecord' and 'startingAttribute' to
  2301. find the next occurrence of the value.
  2302. }
  2303.     DirFindValuePBPtr = ^DirFindValuePB;
  2304.     DirFindValuePB = RECORD
  2305.         qLink:                    Ptr;
  2306.         reserved1:                LONGINT;
  2307.         reserved2:                LONGINT;
  2308.         ioCompletion:            DirIOCompletionUPP;
  2309.         ioResult:                OSErr;
  2310.         saveA5:                    UInt32;
  2311.         reqCode:                INTEGER;
  2312.         reserved:                ARRAY [0..1] OF LONGINT;
  2313.         serverHint:                AddrBlock;
  2314.         dsRefNum:                INTEGER;
  2315.         callID:                    UInt32;
  2316.         identity:                AuthIdentity;
  2317.         gReserved1:                LONGINT;
  2318.         gReserved2:                LONGINT;
  2319.         gReserved3:                LONGINT;
  2320.         clientData:                LONGINT;
  2321.         aRLI:                    PackedRLIPtr;                            {   --> an RLI specifying the cluster to be enumerated  }
  2322.         aRecord:                LocalRecordIDPtr;                        {   --> if not nil, look only in this record  }
  2323.         attrType:                AttributeTypePtr;                        {   --> if not nil, look only in this attribute type  }
  2324.         startingRecord:            LocalRecordIDPtr;                        {   --> record in which to start searching  }
  2325.         startingAttribute:        AttributePtr;                            {   --> attribute in which to start searching  }
  2326.         recordFound:            LocalRecordIDPtr;                        {  <--  record in which data was found  }
  2327.         attributeFound:            Attribute;                                {  <--  attribute in which data was found  }
  2328.         matchSize:                UInt32;                                    {   --> length of matching bytes  }
  2329.         matchingData:            Ptr;                                    {   --> data bytes to be matched in search  }
  2330.         sortDirection:            DirSortDirection;                        {   --> sort direction (forwards or backwards)  }
  2331.     END;
  2332.  
  2333.  
  2334.  
  2335. {
  2336. EnumeratePseudonymGet:
  2337. This call can be used to enumerate the existing pseudonyms for
  2338. a given record specified in 'aRecord'. A starting point can be specified
  2339. by 'startingName' and 'startingType'. If the 'includeStartingPoint' boolean
  2340. is true and a starting point is specified, the name specified by startingName
  2341. and startingType also is returned in the results, if it exists. If this is set to false,
  2342. the pseudonym in startingName and Type is not included.
  2343. Pseudonyms returned in the 'getBuffer' can be extracted by making an
  2344. EnumeratePseudonymParse call. The results will consist of a RecordID with the
  2345. name and type of the pseudonym. If the buffer could not hold all the results, then
  2346. 'kOCEMoreData' error will be returned. The user will be able to continue the call by
  2347. using the last result returned as starting point for the next call.
  2348. }
  2349.     DirEnumeratePseudonymGetPBPtr = ^DirEnumeratePseudonymGetPB;
  2350.     DirEnumeratePseudonymGetPB = RECORD
  2351.         qLink:                    Ptr;
  2352.         reserved1:                LONGINT;
  2353.         reserved2:                LONGINT;
  2354.         ioCompletion:            DirIOCompletionUPP;
  2355.         ioResult:                OSErr;
  2356.         saveA5:                    UInt32;
  2357.         reqCode:                INTEGER;
  2358.         reserved:                ARRAY [0..1] OF LONGINT;
  2359.         serverHint:                AddrBlock;
  2360.         dsRefNum:                INTEGER;
  2361.         callID:                    UInt32;
  2362.         identity:                AuthIdentity;
  2363.         gReserved1:                LONGINT;
  2364.         gReserved2:                LONGINT;
  2365.         gReserved3:                LONGINT;
  2366.         clientData:                LONGINT;
  2367.         aRecord:                RecordIDPtr;                            {   -->  }
  2368.         startingName:            RStringPtr;                                {   -->  }
  2369.         startingType:            RStringPtr;                                {   -->  }
  2370.         dReserved:                LONGINT;                                {   --   }
  2371.         eReserved:                LONGINT;                                {   --   }
  2372.         fReserved:                LONGINT;                                {   --   }
  2373.         gReserved:                LONGINT;                                {   --   }
  2374.         hReserved:                LONGINT;                                {   --   }
  2375.         includeStartingPoint:    BOOLEAN;                                {   --> if true return the Pseudonym specified by starting point will be included  }
  2376.         padByte:                SInt8;
  2377.         i1Reserved:                INTEGER;                                {   --   }
  2378.         getBuffer:                Ptr;                                    {   -->  }
  2379.         getBufferSize:            UInt32;                                    {   -->  }
  2380.     END;
  2381.  
  2382. { The call-back function is defined as follows: }
  2383. {$IFC TYPED_FUNCTION_POINTERS}
  2384.     ForEachRecordIDProcPtr = FUNCTION(clientData: LONGINT; {CONST}VAR recordID: RecordID): BOOLEAN;
  2385. {$ELSEC}
  2386.     ForEachRecordIDProcPtr = ProcPtr;
  2387. {$ENDC}
  2388.  
  2389.     ForEachRecordIDUPP = UniversalProcPtr;
  2390.     ForEachRecordID                        = ForEachRecordIDUPP;
  2391. {
  2392. EnumeratePseudonymParse:
  2393. The pseudonyms returned in the 'getBuffer' from the EnumeratePseudonymGet call
  2394. can be extracted by using the EnumeratePseudonymParse call. 'eachRecordID'
  2395. will be called for each pseudonym.
  2396.  
  2397. Returning true from any call-back will terminate the EnumeratePseudonymParse call.
  2398.  
  2399. For synchronous calls, the call-back routine actually runs as part of the same thread
  2400. of execution as the thread that made the EnumeratePseudonymParse call.  That means that the
  2401. same low-memory globals, A5, stack, etc. are in effect during the call-back
  2402. that were in effect when the call was made.  Because of this, the call-back
  2403. routine has the same restrictions as the caller of EnumeratePseudonymParse:
  2404. if EnumeratePseudonymParse was not called from interrupt level, then the call-
  2405. back routine can allocate memory. For asynchronous calls, call-back routine is
  2406. like a ioCompletion except that A5 will be preserved for the application.
  2407. }
  2408.     DirEnumeratePseudonymParsePBPtr = ^DirEnumeratePseudonymParsePB;
  2409.     DirEnumeratePseudonymParsePB = RECORD
  2410.         qLink:                    Ptr;
  2411.         reserved1:                LONGINT;
  2412.         reserved2:                LONGINT;
  2413.         ioCompletion:            DirIOCompletionUPP;
  2414.         ioResult:                OSErr;
  2415.         saveA5:                    UInt32;
  2416.         reqCode:                INTEGER;
  2417.         reserved:                ARRAY [0..1] OF LONGINT;
  2418.         serverHint:                AddrBlock;
  2419.         dsRefNum:                INTEGER;
  2420.         callID:                    UInt32;
  2421.         identity:                AuthIdentity;
  2422.         gReserved1:                LONGINT;
  2423.         gReserved2:                LONGINT;
  2424.         gReserved3:                LONGINT;
  2425.         clientData:                LONGINT;
  2426.         aRecord:                RecordIDPtr;                            {   --> same as DirEnumerateAliasesGetPB  }
  2427.         bReserved:                LONGINT;                                {   --   }
  2428.         cReserved:                LONGINT;                                {   --   }
  2429.         eachRecordID:            ForEachRecordID;                        {   -->  }
  2430.         eReserved:                LONGINT;                                {   --   }
  2431.         fReserved:                LONGINT;                                {   --   }
  2432.         gReserved:                LONGINT;                                {   --   }
  2433.         hReserved:                LONGINT;                                {   --   }
  2434.         iReserved:                LONGINT;                                {   --   }
  2435.         getBuffer:                Ptr;                                    {   -->  }
  2436.         getBufferSize:            UInt32;                                    {   -->  }
  2437.     END;
  2438.  
  2439.  
  2440.  
  2441. { GetNameAndType }
  2442.     DirGetNameAndTypePBPtr = ^DirGetNameAndTypePB;
  2443.     DirGetNameAndTypePB = RECORD
  2444.         qLink:                    Ptr;
  2445.         reserved1:                LONGINT;
  2446.         reserved2:                LONGINT;
  2447.         ioCompletion:            DirIOCompletionUPP;
  2448.         ioResult:                OSErr;
  2449.         saveA5:                    UInt32;
  2450.         reqCode:                INTEGER;
  2451.         reserved:                ARRAY [0..1] OF LONGINT;
  2452.         serverHint:                AddrBlock;
  2453.         dsRefNum:                INTEGER;
  2454.         callID:                    UInt32;
  2455.         identity:                AuthIdentity;
  2456.         gReserved1:                LONGINT;
  2457.         gReserved2:                LONGINT;
  2458.         gReserved3:                LONGINT;
  2459.         clientData:                LONGINT;
  2460.         aRecord:                RecordIDPtr;                            {   -->  }
  2461.     END;
  2462.  
  2463. {
  2464. aRecord must contain valid RLI and a CreationID.  It
  2465. must also contain pointers to maximum-length RStrings (name and type fields)
  2466. in which will be returned the record's distinguished name and type.
  2467. }
  2468.  
  2469. {
  2470. SetNameAndType:
  2471. This call can be used to change a name and type for a record. The record
  2472. to be renamed is specified using 'aRecord'.
  2473. 'newName' and 'newType' indicate the name and type to be set.
  2474. 'allowDuplicate' if true indicates that name is to be set even if another
  2475. name and type exactly matches the newName and newType specified.
  2476.  
  2477. 'newName' and 'newType' are required since the catalogs not supporting
  2478. CreationID require name and type fields in the recordID to identify a given
  2479. record.
  2480. }
  2481.     DirSetNameAndTypePBPtr = ^DirSetNameAndTypePB;
  2482.     DirSetNameAndTypePB = RECORD
  2483.         qLink:                    Ptr;
  2484.         reserved1:                LONGINT;
  2485.         reserved2:                LONGINT;
  2486.         ioCompletion:            DirIOCompletionUPP;
  2487.         ioResult:                OSErr;
  2488.         saveA5:                    UInt32;
  2489.         reqCode:                INTEGER;
  2490.         reserved:                ARRAY [0..1] OF LONGINT;
  2491.         serverHint:                AddrBlock;
  2492.         dsRefNum:                INTEGER;
  2493.         callID:                    UInt32;
  2494.         identity:                AuthIdentity;
  2495.         gReserved1:                LONGINT;
  2496.         gReserved2:                LONGINT;
  2497.         gReserved3:                LONGINT;
  2498.         clientData:                LONGINT;
  2499.         aRecord:                RecordIDPtr;                            {   -->  }
  2500.         allowDuplicate:            BOOLEAN;                                {   -->  }
  2501.         padByte:                SInt8;
  2502.         newName:                RStringPtr;                                {   --> new name for the record  }
  2503.         newType:                RStringPtr;                                {   --> new type for the record  }
  2504.     END;
  2505.  
  2506.  
  2507.  
  2508.  
  2509. {
  2510. DirGetMetaRecordInfo: This call can be made to obtain
  2511. the MetaRecordInfo for a given record. Information returned
  2512. is 16 bytes of OPAQUE information about the record.
  2513. }
  2514.     DirGetRecordMetaInfoPBPtr = ^DirGetRecordMetaInfoPB;
  2515.     DirGetRecordMetaInfoPB = RECORD
  2516.         qLink:                    Ptr;
  2517.         reserved1:                LONGINT;
  2518.         reserved2:                LONGINT;
  2519.         ioCompletion:            DirIOCompletionUPP;
  2520.         ioResult:                OSErr;
  2521.         saveA5:                    UInt32;
  2522.         reqCode:                INTEGER;
  2523.         reserved:                ARRAY [0..1] OF LONGINT;
  2524.         serverHint:                AddrBlock;
  2525.         dsRefNum:                INTEGER;
  2526.         callID:                    UInt32;
  2527.         identity:                AuthIdentity;
  2528.         gReserved1:                LONGINT;
  2529.         gReserved2:                LONGINT;
  2530.         gReserved3:                LONGINT;
  2531.         clientData:                LONGINT;
  2532.         aRecord:                RecordIDPtr;                            {   -->  }
  2533.         metaInfo:                DirMetaInfo;                            {  <--   }
  2534.     END;
  2535.  
  2536.  
  2537. {
  2538. DirGetDNodeMetaInfo: This call can be made to obtain
  2539. the DNodeMetaInfo for a given Packed RLI. Information returned
  2540. is 16 bytes of OPAQUE information about the DNode.
  2541. }
  2542.     DirGetDNodeMetaInfoPBPtr = ^DirGetDNodeMetaInfoPB;
  2543.     DirGetDNodeMetaInfoPB = RECORD
  2544.         qLink:                    Ptr;
  2545.         reserved1:                LONGINT;
  2546.         reserved2:                LONGINT;
  2547.         ioCompletion:            DirIOCompletionUPP;
  2548.         ioResult:                OSErr;
  2549.         saveA5:                    UInt32;
  2550.         reqCode:                INTEGER;
  2551.         reserved:                ARRAY [0..1] OF LONGINT;
  2552.         serverHint:                AddrBlock;
  2553.         dsRefNum:                INTEGER;
  2554.         callID:                    UInt32;
  2555.         identity:                AuthIdentity;
  2556.         gReserved1:                LONGINT;
  2557.         gReserved2:                LONGINT;
  2558.         gReserved3:                LONGINT;
  2559.         clientData:                LONGINT;
  2560.         pRLI:                    PackedRLIPtr;                            {   -->  }
  2561.         metaInfo:                DirMetaInfo;                            {  <--   }
  2562.     END;
  2563.  
  2564.  
  2565. {
  2566. EnumerateDirectoriesGet:
  2567. A user can enumerate all the catalogs installed. This includes installed
  2568. ADAP and CSAM catalogs. The user can specify a signature as input to restrict
  2569. the results. kDirADAPKind will return only ADAP catalogs, kDirDSAMKind
  2570. will return all CSAM catalogs. kDirAllKinds will get both ADAP & CSAM catalogs.
  2571. A specific signature (e.g. X.500) may be used to get catalogs with an X.500 signature.
  2572. The information for each catalog returned will have directoryName, discriminator and features.
  2573.  
  2574. If the user receives 'noErr' or 'kOCEMoreData', the buffer will contain valid results. A user
  2575. can extract the results in the 'getBuffer' by making an DirEnumerateDirectories call.
  2576.  
  2577. If 'kOCEMoreData' is received, the user can continue enumeration by using the last catalog and
  2578. discriminator as startingDirectoryName and staringDirDiscriminator in the next call.
  2579.  
  2580. If 'includeStartingPoint' is true and a starting point is specified,
  2581. the staring point will be returned in the result. If false, it is not included.
  2582. }
  2583.     DirEnumerateDirectoriesGetPBPtr = ^DirEnumerateDirectoriesGetPB;
  2584.     DirEnumerateDirectoriesGetPB = RECORD
  2585.         qLink:                    Ptr;
  2586.         reserved1:                LONGINT;
  2587.         reserved2:                LONGINT;
  2588.         ioCompletion:            DirIOCompletionUPP;
  2589.         ioResult:                OSErr;
  2590.         saveA5:                    UInt32;
  2591.         reqCode:                INTEGER;
  2592.         reserved:                ARRAY [0..1] OF LONGINT;
  2593.         serverHint:                AddrBlock;
  2594.         dsRefNum:                INTEGER;
  2595.         callID:                    UInt32;
  2596.         identity:                AuthIdentity;
  2597.         gReserved1:                LONGINT;
  2598.         gReserved2:                LONGINT;
  2599.         gReserved3:                LONGINT;
  2600.         clientData:                LONGINT;
  2601.         directoryKind:            OCEDirectoryKind;                        {   --> enumerate catalogs bearing this signature  }
  2602.         startingDirectoryName:    DirectoryNamePtr;                        {   --> staring catalog name  }
  2603.         startingDirDiscriminator: DirDiscriminator;                        {   --> staring catalog discriminator  }
  2604.         eReserved:                LONGINT;                                {   --   }
  2605.         fReserved:                LONGINT;                                {   --   }
  2606.         gReserved:                LONGINT;                                {   --   }
  2607.         hReserved:                LONGINT;                                {   --   }
  2608.         includeStartingPoint:    BOOLEAN;                                {   --> if true return the catalog specified by starting point  }
  2609.         padByte:                SInt8;
  2610.         i1Reserved:                INTEGER;                                {   --   }
  2611.         getBuffer:                Ptr;                                    {   -->  }
  2612.         getBufferSize:            UInt32;                                    {   -->  }
  2613.     END;
  2614.  
  2615.  
  2616.  
  2617. {$IFC TYPED_FUNCTION_POINTERS}
  2618.     ForEachDirectoryProcPtr = FUNCTION(clientData: LONGINT; {CONST}VAR dirName: DirectoryName; {CONST}VAR discriminator: DirDiscriminator; features: DirGestalt): BOOLEAN;
  2619. {$ELSEC}
  2620.     ForEachDirectoryProcPtr = ProcPtr;
  2621. {$ENDC}
  2622.  
  2623.     ForEachDirectoryUPP = UniversalProcPtr;
  2624.     ForEachDirectory                    = ForEachDirectoryUPP;
  2625. {
  2626. EnumerateDirectoriesParse:
  2627. The catalog info returned in 'getBuffer' from the EnumerateDirectoriesGet call
  2628. can be extracted using the EnumerateDirectoriesParse call. 'eachDirectory' will
  2629. be called for each catalog.
  2630.  
  2631. Returning true from any call-back will terminate the EnumerateDirectoriesParse call.
  2632.  
  2633. For synchronous calls, the call-back routine actually runs as part of the same thread
  2634. of execution as the thread that made the EnumerateDirectoriesParse call.  That means that the
  2635. same low-memory globals, A5, stack, etc. are in effect during the call-back
  2636. that were in effect when the call was made.  Because of this, the call-back
  2637. routine has the same restrictions as the caller of EnumerateDirectoriesParse:
  2638. if EnumerateDirectoriesParse was not called from interrupt level, then the call-
  2639. back routine can allocate memory. For asynchronous calls, call-back routine is
  2640. like a ioCompletion except that A5 will be preserved for the application.
  2641.  
  2642. eachDirectory will be called each time to return to the client a
  2643. DirectoryName, DirDiscriminator, and features for that catalog.
  2644. }
  2645.     DirEnumerateDirectoriesParsePBPtr = ^DirEnumerateDirectoriesParsePB;
  2646.     DirEnumerateDirectoriesParsePB = RECORD
  2647.         qLink:                    Ptr;
  2648.         reserved1:                LONGINT;
  2649.         reserved2:                LONGINT;
  2650.         ioCompletion:            DirIOCompletionUPP;
  2651.         ioResult:                OSErr;
  2652.         saveA5:                    UInt32;
  2653.         reqCode:                INTEGER;
  2654.         reserved:                ARRAY [0..1] OF LONGINT;
  2655.         serverHint:                AddrBlock;
  2656.         dsRefNum:                INTEGER;
  2657.         callID:                    UInt32;
  2658.         identity:                AuthIdentity;
  2659.         gReserved1:                LONGINT;
  2660.         gReserved2:                LONGINT;
  2661.         gReserved3:                LONGINT;
  2662.         clientData:                LONGINT;
  2663.         aReserved:                LONGINT;                                {   --   }
  2664.         bReserved:                LONGINT;                                {   --   }
  2665.         cReserved:                LONGINT;                                {   --   }
  2666.         dReserved:                LONGINT;                                {   --   }
  2667.         eachDirectory:            ForEachDirectory;                        {   -->  }
  2668.         fReserved:                LONGINT;                                {   --   }
  2669.         gReserved:                LONGINT;                                {   --   }
  2670.         hReserved:                LONGINT;                                {   --   }
  2671.         iReserved:                LONGINT;                                {   --   }
  2672.         getBuffer:                Ptr;                                    {   -->  }
  2673.         getBufferSize:            UInt32;                                    {   -->  }
  2674.     END;
  2675.  
  2676.  
  2677. {
  2678. The Following five call are specific to ADAP Catalogs. Toolbox
  2679. remembers a list of catalogs across boots. If any catalog service
  2680. call is intended for a ADAP catalog, then it must be in the list.
  2681. In order for managing this list, A client (Probably DE will use these
  2682. calls.
  2683. DirAddADAPDirectoryPB: Add a new ADAP catalog to the list.
  2684. DirRemoveADAPDirectory: Remove a ADAP catalog from the list.
  2685. DirNetSearchADAPDirectoriesGet:   search an internet for adas catalogs.
  2686. DirNetSearchADAPDirectoriesParse: extract the results obtained NetSearchADAPDirectoriesGet.
  2687. DirFindADAPDirectoryByNetSearch: Find a specified catalog through net search.
  2688. }
  2689. {
  2690. NetSearchADAPDirectoriesGet:
  2691. This call can be used to make a network wide search for finding ADAP catalogs.
  2692. This call will be supported only by 'ADAP' and involve highly expensive
  2693. network operations, so the user is advised to use utmost discretion before
  2694. making this call. The results will be collected in the 'getbuffer' and can be
  2695. extracted using NetSearchADAPDirectoriesParse call. The directoryName,
  2696. the directoryDiscriminator, features and serverHint (AppleTalk address for
  2697. a PathFinder serving that catalog) are collected for each catalog found
  2698. on the network. If buffer is too small to hold all the catalogs found on
  2699. the network, a 'kOCEMoreData' error will be returned.
  2700. }
  2701.     DirNetSearchADAPDirectoriesGetPBPtr = ^DirNetSearchADAPDirectoriesGetPB;
  2702.     DirNetSearchADAPDirectoriesGetPB = RECORD
  2703.         qLink:                    Ptr;
  2704.         reserved1:                LONGINT;
  2705.         reserved2:                LONGINT;
  2706.         ioCompletion:            DirIOCompletionUPP;
  2707.         ioResult:                OSErr;
  2708.         saveA5:                    UInt32;
  2709.         reqCode:                INTEGER;
  2710.         reserved:                ARRAY [0..1] OF LONGINT;
  2711.         serverHint:                AddrBlock;
  2712.         dsRefNum:                INTEGER;
  2713.         callID:                    UInt32;
  2714.         identity:                AuthIdentity;
  2715.         gReserved1:                LONGINT;
  2716.         gReserved2:                LONGINT;
  2717.         gReserved3:                LONGINT;
  2718.         clientData:                LONGINT;
  2719.         getBuffer:                Ptr;                                    {   -->  }
  2720.         getBufferSize:            UInt32;                                    {   -->  }
  2721.         cReserved:                LONGINT;                                {   --   }
  2722.     END;
  2723.  
  2724. {$IFC TYPED_FUNCTION_POINTERS}
  2725.     ForEachADAPDirectoryProcPtr = FUNCTION(clientData: LONGINT; {CONST}VAR dirName: DirectoryName; {CONST}VAR discriminator: DirDiscriminator; features: DirGestalt; serverHint: AddrBlock): BOOLEAN;
  2726. {$ELSEC}
  2727.     ForEachADAPDirectoryProcPtr = ProcPtr;
  2728. {$ENDC}
  2729.  
  2730.     ForEachADAPDirectoryUPP = UniversalProcPtr;
  2731.     ForEachADAPDirectory                = ForEachADAPDirectoryUPP;
  2732. {
  2733. DirNetSearchADAPDirectoriesParse:
  2734. This call can be used to extract the results obtained in the 'getBuffer'.
  2735. The directoryName, directoryDiscriminator, features and
  2736. serverHint (AppleTalk address for a PathFinder serving that catalog) are
  2737. returned in each call-back. These values may be used to make an
  2738. AddADAPDirectory call.
  2739.  
  2740. Returning TRUE from any call-back will terminate the NetSearchADAPDirectoriesParse request.
  2741.  
  2742. For synchronous calls, the call-back routine actually runs as part of the same thread
  2743. of execution as the thread that made the DirNetSearchADAPDirectoriesParse call. That means that the
  2744. same low-memory globals, A5, stack, etc. are in effect during the call-back
  2745. that were in effect when the call was made.  Because of this, the call-back
  2746. routine has the same restrictions as the caller of DirNetSearchADAPDirectoriesParse:
  2747. if DirNetSearchADAPDirectoriesParse was not called from interrupt level, then the call-
  2748. back routine can allocate memory. For asynchronous calls, call-back routine is
  2749. like a ioCompletion except that A5 will be preserved for the application.
  2750. }
  2751.     DirNetSearchADAPDirectoriesParsePBPtr = ^DirNetSearchADAPDirectoriesParsePB;
  2752.     DirNetSearchADAPDirectoriesParsePB = RECORD
  2753.         qLink:                    Ptr;
  2754.         reserved1:                LONGINT;
  2755.         reserved2:                LONGINT;
  2756.         ioCompletion:            DirIOCompletionUPP;
  2757.         ioResult:                OSErr;
  2758.         saveA5:                    UInt32;
  2759.         reqCode:                INTEGER;
  2760.         reserved:                ARRAY [0..1] OF LONGINT;
  2761.         serverHint:                AddrBlock;
  2762.         dsRefNum:                INTEGER;
  2763.         callID:                    UInt32;
  2764.         identity:                AuthIdentity;
  2765.         gReserved1:                LONGINT;
  2766.         gReserved2:                LONGINT;
  2767.         gReserved3:                LONGINT;
  2768.         clientData:                LONGINT;
  2769.         getBuffer:                Ptr;                                    {   -->  }
  2770.         getBufferSize:            UInt32;                                    {   -->  }
  2771.         eachADAPDirectory:        ForEachADAPDirectory;                    {   -->  }
  2772.     END;
  2773.  
  2774. {
  2775. DirFindADAPDirectoryByNetSearch:
  2776. This call can be used to make a network wide search to find an ADAP catalog.
  2777. This call will be supported only by 'ADAP' and involves highly expensive
  2778. network operations, so the user is advised to use utmost discretion before
  2779. making this call. The catalog is specified using directoryName and discriminator.
  2780. If 'addToOCESetup' is true, the catalog will be automatically added to the setup
  2781. list and will be visible through the EnumerateDirectories call and also
  2782. also a creationID to the directoryRecord will be returned.
  2783. If this parameter is set to 'false', the catalog will be added to temporary list
  2784. and will be available for making other catalog service calls. The catalogs
  2785. which are not in the preference catalog list will not be visible through the
  2786. EnumerateDirectories call.
  2787. }
  2788.     DirFindADAPDirectoryByNetSearchPBPtr = ^DirFindADAPDirectoryByNetSearchPB;
  2789.     DirFindADAPDirectoryByNetSearchPB = RECORD
  2790.         qLink:                    Ptr;
  2791.         reserved1:                LONGINT;
  2792.         reserved2:                LONGINT;
  2793.         ioCompletion:            DirIOCompletionUPP;
  2794.         ioResult:                OSErr;
  2795.         saveA5:                    UInt32;
  2796.         reqCode:                INTEGER;
  2797.         reserved:                ARRAY [0..1] OF LONGINT;
  2798.         serverHint:                AddrBlock;
  2799.         dsRefNum:                INTEGER;
  2800.         callID:                    UInt32;
  2801.         identity:                AuthIdentity;
  2802.         gReserved1:                LONGINT;
  2803.         gReserved2:                LONGINT;
  2804.         gReserved3:                LONGINT;
  2805.         clientData:                LONGINT;
  2806.         directoryName:            DirectoryNamePtr;                        {   --> catalog name  }
  2807.         discriminator:            DirDiscriminator;                        {   --> discriminate between dup catalog names  }
  2808.         addToOCESetup:            BOOLEAN;                                {   --> add this catalog to OCE Setup List  }
  2809.         padByte:                SInt8;
  2810.         directoryRecordCID:        CreationID;                                {  <--  creationID for the catalog record  }
  2811.     END;
  2812.  
  2813.  
  2814. {
  2815. DirAddADAPDirectory:
  2816. The catalog specified by 'directoryName' and 'discriminator' will be
  2817. added to the list of catalogs maintained by the Toolbox. Once added,
  2818. the catalog is available across boots, until the catalog is removed
  2819. explicitly through a DirRemoveADAPDirectory call.
  2820. If 'serverHint' is not nil, the address provided will be used
  2821. to contact a PathFinder for the catalog specified.
  2822. If 'serverHint' is nil or does not point to a valid PathFinder server
  2823. for that catalog, this call will fail.
  2824. If 'addToOCESetup' is true, the catalog will be automatically added to the setup
  2825. catalog list and will be visible through EnumerateDirectories calls and
  2826. also a creationID to the directoryRecord will be returned.
  2827. If this parameter is set to 'false', catalog will be added to temprary list
  2828. and will be available for making other catalog service calls. The catalogs
  2829. which are not in the setup  list will not be visible through
  2830. EnumerateDirectories call.
  2831. }
  2832.     DirAddADAPDirectoryPBPtr = ^DirAddADAPDirectoryPB;
  2833.     DirAddADAPDirectoryPB = RECORD
  2834.         qLink:                    Ptr;
  2835.         reserved1:                LONGINT;
  2836.         reserved2:                LONGINT;
  2837.         ioCompletion:            DirIOCompletionUPP;
  2838.         ioResult:                OSErr;
  2839.         saveA5:                    UInt32;
  2840.         reqCode:                INTEGER;
  2841.         reserved:                ARRAY [0..1] OF LONGINT;
  2842.         serverHint:                AddrBlock;
  2843.         dsRefNum:                INTEGER;
  2844.         callID:                    UInt32;
  2845.         identity:                AuthIdentity;
  2846.         gReserved1:                LONGINT;
  2847.         gReserved2:                LONGINT;
  2848.         gReserved3:                LONGINT;
  2849.         clientData:                LONGINT;
  2850.         directoryName:            DirectoryNamePtr;                        {   --> catalog name  }
  2851.         discriminator:            DirDiscriminator;                        {   --> discriminate between dup catalog names  }
  2852.         addToOCESetup:            BOOLEAN;                                {   --> add this catalog to OCE Setup  }
  2853.         padByte:                SInt8;
  2854.         directoryRecordCID:        CreationID;                                {  <--  creationID for the catalog record  }
  2855.     END;
  2856.  
  2857.  
  2858.  
  2859. {
  2860. GetDirectoryInfo:
  2861. DirGetDirectoryInfo will do:
  2862.  
  2863. If a 'dsRefNum' is non-Zero, the catalog information for
  2864.     the corresponding  PAB will be  returned.
  2865.  If 'dsRefNum' is zero and 'serverHint' is non-zero, If the
  2866.  'serverHint' points to a valid ADAP Catalog Server(Path Finder),
  2867.  the catalog information (i.e. directoryName, discriminator, features)
  2868.  for that catalog will be returned.
  2869.     If a  valid catalog name and discriminator are provided
  2870.     features (Set of capability flags) for that catalog will be returned.
  2871. }
  2872.     DirGetDirectoryInfoPBPtr = ^DirGetDirectoryInfoPB;
  2873.     DirGetDirectoryInfoPB = RECORD
  2874.         qLink:                    Ptr;
  2875.         reserved1:                LONGINT;
  2876.         reserved2:                LONGINT;
  2877.         ioCompletion:            DirIOCompletionUPP;
  2878.         ioResult:                OSErr;
  2879.         saveA5:                    UInt32;
  2880.         reqCode:                INTEGER;
  2881.         reserved:                ARRAY [0..1] OF LONGINT;
  2882.         serverHint:                AddrBlock;
  2883.         dsRefNum:                INTEGER;
  2884.         callID:                    UInt32;
  2885.         identity:                AuthIdentity;
  2886.         gReserved1:                LONGINT;
  2887.         gReserved2:                LONGINT;
  2888.         gReserved3:                LONGINT;
  2889.         clientData:                LONGINT;
  2890.         directoryName:            DirectoryNamePtr;                        {   --> catalog name  }
  2891.         discriminator:            DirDiscriminator;                        {  <--> descriminate between dup catalog names  }
  2892.         features:                DirGestalt;                                {  <--  capability bit flags  }
  2893.     END;
  2894.  
  2895.  
  2896. {
  2897.  * Note on Access Controls:
  2898.  * Access control is based on a list model.
  2899.  * You can get access controls list which gives dsObject and accMask for each dsObject.
  2900.  * GetAccessControl can be limited to currently supplied identity by setting forCurrentUserOnly.
  2901.  * There are special DSObjects are defined in ADASTypes.h for each of the category
  2902.  * supported in ADAS Catalogs. (kOwner, kFriends, kAuthenticatedToCluster, 
  2903.  * kAuthenticatedToDirectory, kGuest) and DUGetActlDSSpec call can be used
  2904.  * to obtain appropraiate DSSpec before making set calls to ADAS catalogs.
  2905.  *
  2906.  }
  2907.  
  2908.  
  2909.  
  2910.  
  2911.  
  2912. {
  2913.     GetDNodeAccessControlGet:
  2914.     This call can be done to get back access control list for a DNode.
  2915.     pRLI -> RLI of the DNode whose access control list is sought
  2916.     curUserAccMask -> If this is 'true', Access controls for the user specified by
  2917.                       the identity parameter will be returned other wise entire list
  2918.                       will be returned.
  2919.     startingDsObj  -> If this is not nil, list should be started after this object.
  2920.     startingPointInclusive -> If staringDsObj is specified, include that in the returned
  2921.                               results.
  2922.                               
  2923.     The results will be collected in the 'getBuffer' supplied by the user.
  2924.     If buffer can not hold all the data returned 'daMoreData' error will be returned.
  2925.      
  2926.     If user receives 'noErr' or 'daMoreData', buffer will contain valid results. A user
  2927.     can extract the results in the 'getBuffer' by making 'DsGetDNodeAccessControlParse' call.
  2928.     
  2929.     Results returned for each DSObject will contain DSSpecPtr and three sets of access mask. 
  2930.  
  2931. }
  2932.  
  2933.     DirGetDNodeAccessControlGetPBPtr = ^DirGetDNodeAccessControlGetPB;
  2934.     DirGetDNodeAccessControlGetPB = RECORD
  2935.         qLink:                    Ptr;
  2936.         reserved1:                LONGINT;
  2937.         reserved2:                LONGINT;
  2938.         ioCompletion:            DirIOCompletionUPP;
  2939.         ioResult:                OSErr;
  2940.         saveA5:                    UInt32;
  2941.         reqCode:                INTEGER;
  2942.         reserved:                ARRAY [0..1] OF LONGINT;
  2943.         serverHint:                AddrBlock;
  2944.         dsRefNum:                INTEGER;
  2945.         callID:                    UInt32;
  2946.         identity:                AuthIdentity;
  2947.         gReserved1:                LONGINT;
  2948.         gReserved2:                LONGINT;
  2949.         gReserved3:                LONGINT;
  2950.         clientData:                LONGINT;
  2951.         pRLI:                    PackedRLIPtr;                            {   -> RLI of the cluster whose access control list is sought   }
  2952.         bReserved:                LONGINT;                                {   -- unused  }
  2953.         cReserved:                LONGINT;                                {   -- unused  }
  2954.         dReserved:                LONGINT;                                {   -- unused  }
  2955.         eResreved:                LONGINT;                                {  -->  }
  2956.         forCurrentUserOnly:        BOOLEAN;                                {  -->   }
  2957.         filler1:                BOOLEAN;
  2958.         startingPoint:            DSSpecPtr;                                {  --> starting Point  }
  2959.         includeStartingPoint:    BOOLEAN;                                {  --> if true return the DsObject specified in starting point  }
  2960.         filler2:                BOOLEAN;
  2961.         getBuffer:                Ptr;                                    {     ->  }
  2962.         getBufferSize:            UInt32;                                    {   ->  }
  2963.     END;
  2964.  
  2965. { The Access Control call-back function is defined as follows: }
  2966. {$IFC TYPED_FUNCTION_POINTERS}
  2967.     ForEachDNodeAccessControlProcPtr = FUNCTION(clientData: LONGINT; {CONST}VAR dsObj: DSSpec; activeDnodeAccMask: AccessMask; defaultRecordAccMask: AccessMask; defaultAttributeAccMask: AccessMask): BOOLEAN;
  2968. {$ELSEC}
  2969.     ForEachDNodeAccessControlProcPtr = ProcPtr;
  2970. {$ENDC}
  2971.  
  2972.     ForEachDNodeAccessControlUPP = UniversalProcPtr;
  2973.     ForEachDNodeAccessControl            = ForEachDNodeAccessControlUPP;
  2974. {
  2975.     GetDNodeAccessControlParse:
  2976.     After an GetDNodeAccessControlGet call has completed, 
  2977.     call GetDNodeAccessControlParse to parse through the buffer that
  2978.     that was filled in GetDNodeAccessControlGet.
  2979.     
  2980.     'eachObject' will be called each time to return to the client a
  2981.     DsObject and a set of three accMasks (three long words) for that object.
  2982.     Acceesmasks returned apply to the dsObject in the callback :
  2983.     1. Currently Active Access mask for the specified DNode.
  2984.     2. Default Access mask for any Record in the DNode
  2985.     3. Default Access mask for any Attribute in the DNode
  2986.     The clientData parameter that you pass in the parameter block will be passed
  2987.     to 'eachObject'.  You are free to put anything in clientData - it is intended
  2988.     to allow you some way to match the call-back to the original call (for
  2989.     example, you make more then one aysynchronous GetDNodeAccessControlGet calls and you want to
  2990.     associate returned results in some way).
  2991.     
  2992.     The client should return FALSE from 'eachObject' to continue
  2993.     processing of the GetDNodeAccessControlParse request.  Returning TRUE will
  2994.     terminate the GetDNodeAccessControlParse request.
  2995.  
  2996.     For synchronous calls, the call-back routine actually runs as part of the same thread 
  2997.     of execution as the thread that made the GetDNodeAccessControlParse call.  That means that the
  2998.     same low-memory globals, A5, stack, etc. are in effect during the call-back
  2999.     that were in effect when the call was made.  Because of this, the call-back
  3000.     routine has the same restrictions as the caller of GetDNodeAccessControlParse:
  3001.     if GetDNodeAccessControlParse was not called from interrupt level, then the call-
  3002.     back routine can allocate memory. For asynchronous calls, call-back routine is
  3003.     like a ioCompletion except that A5 will be preserved for the application.
  3004.  
  3005.  
  3006. }
  3007.  
  3008.     DirGetDNodeAccessControlParsePBPtr = ^DirGetDNodeAccessControlParsePB;
  3009.     DirGetDNodeAccessControlParsePB = RECORD
  3010.         qLink:                    Ptr;
  3011.         reserved1:                LONGINT;
  3012.         reserved2:                LONGINT;
  3013.         ioCompletion:            DirIOCompletionUPP;
  3014.         ioResult:                OSErr;
  3015.         saveA5:                    UInt32;
  3016.         reqCode:                INTEGER;
  3017.         reserved:                ARRAY [0..1] OF LONGINT;
  3018.         serverHint:                AddrBlock;
  3019.         dsRefNum:                INTEGER;
  3020.         callID:                    UInt32;
  3021.         identity:                AuthIdentity;
  3022.         gReserved1:                LONGINT;
  3023.         gReserved2:                LONGINT;
  3024.         gReserved3:                LONGINT;
  3025.         clientData:                LONGINT;
  3026.         pRLI:                    PackedRLIPtr;                            {   -> RLI of the cluster   }
  3027.         bReserved:                LONGINT;                                {   -- unused  }
  3028.         cReserved:                LONGINT;                                {   -- unused  }
  3029.         dReserved:                LONGINT;                                {   -- unused  }
  3030.         eachObject:                ForEachDNodeAccessControl;                {  -->  }
  3031.         forCurrentUserOnly:        BOOLEAN;                                {  -->   }
  3032.         filler1:                BOOLEAN;
  3033.         startingPoint:            DSSpecPtr;                                {  --> starting Point  }
  3034.         includeStartingPoint:    BOOLEAN;                                {  --> if true return the record specified in starting point  }
  3035.         filler2:                BOOLEAN;
  3036.         getBuffer:                Ptr;                                    {     ->  }
  3037.         getBufferSize:            UInt32;                                    {   ->  }
  3038.     END;
  3039.  
  3040. {
  3041.     GetRecordAccessControlGet:
  3042.     This call can be done to get back access control list for a RecordID.
  3043.     aRecord -> RecordID to which access control list is sought
  3044.     curUserAccMask -> If this is 'true', Access controls for the user specified by
  3045.                       the identity parameter will be returned other wise entire list
  3046.                       will be returned.
  3047.     startingDsObj  -> If this is not nil, list should be started after this object.
  3048.     startingPointInclusive -> If staringDsObj is specified, include that in the returned
  3049.                               results.
  3050.                               
  3051.     The results will be collected in the 'getBuffer' supplied by the user.
  3052.     If buffer can not hold all the data returned 'daMoreData' error will be returned.
  3053.      
  3054.     If user receives 'noErr' or 'daMoreData', buffer will contain valid results. A user
  3055.     can extract the results in the 'getBuffer' by making 'DsGetDNodeAccessControlParse' call.
  3056.     
  3057.     Results returned for each DSObject will contain DSSpecPtr and accMask. 
  3058.  
  3059. }
  3060.  
  3061.     DirGetRecordAccessControlGetPBPtr = ^DirGetRecordAccessControlGetPB;
  3062.     DirGetRecordAccessControlGetPB = RECORD
  3063.         qLink:                    Ptr;
  3064.         reserved1:                LONGINT;
  3065.         reserved2:                LONGINT;
  3066.         ioCompletion:            DirIOCompletionUPP;
  3067.         ioResult:                OSErr;
  3068.         saveA5:                    UInt32;
  3069.         reqCode:                INTEGER;
  3070.         reserved:                ARRAY [0..1] OF LONGINT;
  3071.         serverHint:                AddrBlock;
  3072.         dsRefNum:                INTEGER;
  3073.         callID:                    UInt32;
  3074.         identity:                AuthIdentity;
  3075.         gReserved1:                LONGINT;
  3076.         gReserved2:                LONGINT;
  3077.         gReserved3:                LONGINT;
  3078.         clientData:                LONGINT;
  3079.         aRecord:                RecordIDPtr;                            {   -> RecordID to which access control list is sought list is sought   }
  3080.         bReserved:                LONGINT;                                {   -- unused  }
  3081.         cReserved:                LONGINT;                                {   -- unused  }
  3082.         dReserved:                LONGINT;                                {   -- unused  }
  3083.         eResreved:                LONGINT;                                {  -->  }
  3084.         forCurrentUserOnly:        BOOLEAN;                                {  -->   }
  3085.         filler1:                BOOLEAN;
  3086.         startingPoint:            DSSpecPtr;                                {  --> starting Point  }
  3087.         includeStartingPoint:    BOOLEAN;                                {  --> if true return the record specified in starting point  }
  3088.         filler2:                BOOLEAN;
  3089.         getBuffer:                Ptr;                                    {     ->  }
  3090.         getBufferSize:            UInt32;                                    {   ->  }
  3091.     END;
  3092.  
  3093. { The Access Control call-back function is defined as follows: }
  3094. {$IFC TYPED_FUNCTION_POINTERS}
  3095.     ForEachRecordAccessControlProcPtr = FUNCTION(clientData: LONGINT; {CONST}VAR dsObj: DSSpec; activeDnodeAccMask: AccessMask; activeRecordAccMask: AccessMask; defaultAttributeAccMask: AccessMask): BOOLEAN;
  3096. {$ELSEC}
  3097.     ForEachRecordAccessControlProcPtr = ProcPtr;
  3098. {$ENDC}
  3099.  
  3100.     ForEachRecordAccessControlUPP = UniversalProcPtr;
  3101.     ForEachRecordAccessControl            = ForEachRecordAccessControlUPP;
  3102. {
  3103.     GetRecordAccessControlParse:
  3104.     After an GetRecordAccessControlGet call has completed, 
  3105.     call GetRecordAccessControlParse to parse through the buffer that
  3106.     that was filled in GetRecordAccessControlGet.
  3107.     
  3108.     'eachObject' will be called each time to return to the client a
  3109.     DsObject and a set of three accMasks (three long words) for that object.
  3110.     Acceesmasks returned apply to the dsObject in the callback :
  3111.     1. Active Access mask for the DNode Containing the Record.
  3112.     2. Active Access mask for the Record specified.
  3113.     3. Defualt Access mask for Attributes in the record.
  3114.     The clientData parameter that you pass in the parameter block will be passed
  3115.     to 'eachObject'.  You are free to put anything in clientData - it is intended
  3116.     to allow you some way to match the call-back to the original call (for
  3117.     example, you make more then one aysynchronous GetRecordAccessControlGet calls and you want to
  3118.     associate returned results in some way).
  3119.     
  3120.     The client should return FALSE from 'eachObject' to continue
  3121.     processing of the GetRecordAccessControlParse request.  Returning TRUE will
  3122.     terminate the GetRecordAccessControlParse request.
  3123.  
  3124.     For synchronous calls, the call-back routine actually runs as part of the same thread 
  3125.     of execution as the thread that made the GetRecordAccessControlParse call.  That means that the
  3126.     same low-memory globals, A5, stack, etc. are in effect during the call-back
  3127.     that were in effect when the call was made.  Because of this, the call-back
  3128.     routine has the same restrictions as the caller of GetRecordAccessControlParse:
  3129.     if GetRecordAccessControlParse was not called from interrupt level, then the call-
  3130.     back routine can allocate memory. For asynchronous calls, call-back routine is
  3131.     like a ioCompletion except that A5 will be preserved for the application.
  3132.  
  3133.  
  3134. }
  3135.  
  3136.     DirGetRecordAccessControlParsePBPtr = ^DirGetRecordAccessControlParsePB;
  3137.     DirGetRecordAccessControlParsePB = RECORD
  3138.         qLink:                    Ptr;
  3139.         reserved1:                LONGINT;
  3140.         reserved2:                LONGINT;
  3141.         ioCompletion:            DirIOCompletionUPP;
  3142.         ioResult:                OSErr;
  3143.         saveA5:                    UInt32;
  3144.         reqCode:                INTEGER;
  3145.         reserved:                ARRAY [0..1] OF LONGINT;
  3146.         serverHint:                AddrBlock;
  3147.         dsRefNum:                INTEGER;
  3148.         callID:                    UInt32;
  3149.         identity:                AuthIdentity;
  3150.         gReserved1:                LONGINT;
  3151.         gReserved2:                LONGINT;
  3152.         gReserved3:                LONGINT;
  3153.         clientData:                LONGINT;
  3154.         aRecord:                RecordIDPtr;                            {   -> RecordID to which access control list is sought list is sought   }
  3155.         bReserved:                LONGINT;                                {   -- unused  }
  3156.         cReserved:                LONGINT;                                {   -- unused  }
  3157.         dReserved:                LONGINT;                                {   -- unused  }
  3158.         eachObject:                ForEachRecordAccessControl;                {  -->  }
  3159.         forCurrentUserOnly:        BOOLEAN;                                {  -->   }
  3160.         filler1:                BOOLEAN;
  3161.         startingPoint:            DSSpecPtr;                                {  --> starting Point  }
  3162.         includeStartingPoint:    BOOLEAN;                                {  --> if true return the record specified in starting point  }
  3163.         filler2:                BOOLEAN;
  3164.         getBuffer:                Ptr;                                    {     ->  }
  3165.         getBufferSize:            UInt32;                                    {   ->  }
  3166.     END;
  3167.  
  3168. {
  3169.     GetAttributeAccessControlGet:
  3170.     This call can be done to get back access control list for a attributeType with in a RecordID.
  3171.     aRecord -> RecordID to which access control list is sought
  3172.     aType    -> Attribute Type to which access controls are sought
  3173.     curUserAccMask -> If this is 'true', Access controls for the user specified by
  3174.                       the identity parameter will be returned other wise entire list
  3175.                       will be returned.
  3176.     startingDsObj  -> If this is not nil, list should be started after this object.
  3177.     startingPointInclusive -> If staringDsObj is specified, include that in the returned
  3178.                               results.
  3179.                               
  3180.     The results will be collected in the 'getBuffer' supplied by the user.
  3181.     If buffer can not hold all the data returned 'daMoreData' error will be returned.
  3182.      
  3183.     If user receives 'noErr' or 'daMoreData', buffer will contain valid results. A user
  3184.     can extract the results in the 'getBuffer' by making 'DsGetDNodeAccessControlParse' call.
  3185.     
  3186.     Results returned for each DSObject will contain DSSpecPtr and accMask. 
  3187.  
  3188. }
  3189.  
  3190.     DirGetAttributeAccessControlGetPBPtr = ^DirGetAttributeAccessControlGetPB;
  3191.     DirGetAttributeAccessControlGetPB = RECORD
  3192.         qLink:                    Ptr;
  3193.         reserved1:                LONGINT;
  3194.         reserved2:                LONGINT;
  3195.         ioCompletion:            DirIOCompletionUPP;
  3196.         ioResult:                OSErr;
  3197.         saveA5:                    UInt32;
  3198.         reqCode:                INTEGER;
  3199.         reserved:                ARRAY [0..1] OF LONGINT;
  3200.         serverHint:                AddrBlock;
  3201.         dsRefNum:                INTEGER;
  3202.         callID:                    UInt32;
  3203.         identity:                AuthIdentity;
  3204.         gReserved1:                LONGINT;
  3205.         gReserved2:                LONGINT;
  3206.         gReserved3:                LONGINT;
  3207.         clientData:                LONGINT;
  3208.         aRecord:                RecordIDPtr;                            {   -> RecordID to which access control list is sought list is sought   }
  3209.         aType:                    AttributeTypePtr;                        {   -> Attribute Type to which access controls are sought           }
  3210.         cReserved:                LONGINT;                                {   -- unused  }
  3211.         dReserved:                LONGINT;                                {   -- unused  }
  3212.         eResreved:                LONGINT;                                {  -->  }
  3213.         forCurrentUserOnly:        BOOLEAN;                                {  -->   }
  3214.         filler1:                BOOLEAN;
  3215.         startingPoint:            DSSpecPtr;                                {  --> starting Point  }
  3216.         includeStartingPoint:    BOOLEAN;                                {  --> if true return the record specified in starting point  }
  3217.         filler2:                BOOLEAN;
  3218.         getBuffer:                Ptr;                                    {     ->  }
  3219.         getBufferSize:            UInt32;                                    {   ->  }
  3220.     END;
  3221.  
  3222. { The Access Control call-back function is defined as follows: }
  3223. {$IFC TYPED_FUNCTION_POINTERS}
  3224.     ForEachAttributeAccessControlProcPtr = FUNCTION(clientData: LONGINT; {CONST}VAR dsObj: DSSpec; activeDnodeAccMask: AccessMask; activeRecordAccMask: AccessMask; activeAttributeAccMask: AccessMask): BOOLEAN;
  3225. {$ELSEC}
  3226.     ForEachAttributeAccessControlProcPtr = ProcPtr;
  3227. {$ENDC}
  3228.  
  3229.     ForEachAttributeAccessControlUPP = UniversalProcPtr;
  3230.     ForEachAttributeAccessControl        = ForEachAttributeAccessControlUPP;
  3231. {
  3232.     GetAttributeAccessControlParse:
  3233.     After an GetAttributeAccessControlGet call has completed, 
  3234.     call GetAttributeAccessControlParse to parse through the buffer that
  3235.     that was filled in GetAttributeAccessControlGet.
  3236.     
  3237.     'eachObject' will be called each time to return to the client a
  3238.     DsObject and a set of three accMasks (three long words) for that object.
  3239.     Acceesmasks returned apply to the dsObject in the callback :
  3240.     1. Active Access mask for the DNode Containing the Attribute.
  3241.     2. Active Access mask for the Record in the Containing the Attribute.
  3242.     3. Active Access mask for the specified Attribute.
  3243.     The clientData parameter that you pass in the parameter block will be passed
  3244.     to 'eachObject'.  You are free to put anything in clientData - it is intended
  3245.     to allow you some way to match the call-back to the original call (for
  3246.     example, you make more then one aysynchronous GetAttributeAccessControlGet calls and you want to
  3247.     associate returned results in some way).
  3248.     
  3249.     The client should return FALSE from 'eachObject' to continue
  3250.     processing of the GetAttributeAccessControlParse request.  Returning TRUE will
  3251.     terminate the GetAttributeAccessControlParse request.
  3252.  
  3253.     For synchronous calls, the call-back routine actually runs as part of the same thread 
  3254.     of execution as the thread that made the GetAttributeAccessControlParse call.  That means that the
  3255.     same low-memory globals, A5, stack, etc. are in effect during the call-back
  3256.     that were in effect when the call was made.  Because of this, the call-back
  3257.     routine has the same restrictions as the caller of GetAttributeAccessControlParse:
  3258.     if GetAttributeAccessControlParse was not called from interrupt level, then the call-
  3259.     back routine can allocate memory. For asynchronous calls, call-back routine is
  3260.     like a ioCompletion except that A5 will be preserved for the application.
  3261.  
  3262.  
  3263. }
  3264.  
  3265.     DirGetAttributeAccessControlParsePBPtr = ^DirGetAttributeAccessControlParsePB;
  3266.     DirGetAttributeAccessControlParsePB = RECORD
  3267.         qLink:                    Ptr;
  3268.         reserved1:                LONGINT;
  3269.         reserved2:                LONGINT;
  3270.         ioCompletion:            DirIOCompletionUPP;
  3271.         ioResult:                OSErr;
  3272.         saveA5:                    UInt32;
  3273.         reqCode:                INTEGER;
  3274.         reserved:                ARRAY [0..1] OF LONGINT;
  3275.         serverHint:                AddrBlock;
  3276.         dsRefNum:                INTEGER;
  3277.         callID:                    UInt32;
  3278.         identity:                AuthIdentity;
  3279.         gReserved1:                LONGINT;
  3280.         gReserved2:                LONGINT;
  3281.         gReserved3:                LONGINT;
  3282.         clientData:                LONGINT;
  3283.         aRecord:                RecordIDPtr;                            {   -> RecordID to which access control list is sought list is sought   }
  3284.         aType:                    AttributeTypePtr;                        {   -> Attribute Type to which access controls are sought           }
  3285.         cReserved:                LONGINT;                                {   -- unused  }
  3286.         dReserved:                LONGINT;                                {   -- unused  }
  3287.         eachObject:                ForEachAttributeAccessControl;            {  -->  }
  3288.         forCurrentUserOnly:        BOOLEAN;                                {  -->   }
  3289.         filler1:                BOOLEAN;
  3290.         startingPoint:            DSSpecPtr;                                {  --> starting Point  }
  3291.         includeStartingPoint:    BOOLEAN;                                {  --> if true return the record specified in starting point  }
  3292.         filler2:                BOOLEAN;
  3293.         getBuffer:                Ptr;                                    {     ->  }
  3294.         getBufferSize:            UInt32;                                    {   ->  }
  3295.     END;
  3296.  
  3297.  
  3298.  
  3299.  
  3300.  
  3301.  
  3302. {
  3303. MapPathNameToDNodeNumber:
  3304. This call maps a given PathName within a catalog to its DNodeNumber.
  3305. }
  3306.     DirMapPathNameToDNodeNumberPBPtr = ^DirMapPathNameToDNodeNumberPB;
  3307.     DirMapPathNameToDNodeNumberPB = RECORD
  3308.         qLink:                    Ptr;
  3309.         reserved1:                LONGINT;
  3310.         reserved2:                LONGINT;
  3311.         ioCompletion:            DirIOCompletionUPP;
  3312.         ioResult:                OSErr;
  3313.         saveA5:                    UInt32;
  3314.         reqCode:                INTEGER;
  3315.         reserved:                ARRAY [0..1] OF LONGINT;
  3316.         serverHint:                AddrBlock;
  3317.         dsRefNum:                INTEGER;
  3318.         callID:                    UInt32;
  3319.         identity:                AuthIdentity;
  3320.         gReserved1:                LONGINT;
  3321.         gReserved2:                LONGINT;
  3322.         gReserved3:                LONGINT;
  3323.         clientData:                LONGINT;
  3324.         directoryName:            DirectoryNamePtr;                        {   --> catalog name  }
  3325.         discriminator:            DirDiscriminator;                        {   --> discriminator  }
  3326.         dNodeNumber:            DNodeNum;                                {  <--  dNodenumber to the path  }
  3327.         path:                    PackedPathNamePtr;                        {   --> Path Name to be mapped  }
  3328.     END;
  3329.  
  3330. {
  3331. PathName in the path field will be mapped to the cooresponding dNodeNumber and
  3332. returned in the DNodeNumber field. directoryName and descriminator Fields are
  3333. ignored. DSRefNum is used to identify the catalog.
  3334. }
  3335.  
  3336.  
  3337. {
  3338. MapDNodeNumberToPathName:
  3339. This call will map a given DNodeNumber with in a catalog to the
  3340. corresponding PathName.
  3341. }
  3342.     DirMapDNodeNumberToPathNamePBPtr = ^DirMapDNodeNumberToPathNamePB;
  3343.     DirMapDNodeNumberToPathNamePB = RECORD
  3344.         qLink:                    Ptr;
  3345.         reserved1:                LONGINT;
  3346.         reserved2:                LONGINT;
  3347.         ioCompletion:            DirIOCompletionUPP;
  3348.         ioResult:                OSErr;
  3349.         saveA5:                    UInt32;
  3350.         reqCode:                INTEGER;
  3351.         reserved:                ARRAY [0..1] OF LONGINT;
  3352.         serverHint:                AddrBlock;
  3353.         dsRefNum:                INTEGER;
  3354.         callID:                    UInt32;
  3355.         identity:                AuthIdentity;
  3356.         gReserved1:                LONGINT;
  3357.         gReserved2:                LONGINT;
  3358.         gReserved3:                LONGINT;
  3359.         clientData:                LONGINT;
  3360.         directoryName:            DirectoryNamePtr;                        {   --> catalog name  }
  3361.         discriminator:            DirDiscriminator;                        {   --> discriminator  }
  3362.         dNodeNumber:            DNodeNum;                                {   --> dNodenumber to be mapped  }
  3363.         path:                    PackedPathNamePtr;                        {  <--  Packed Path Name returned  }
  3364.         lengthOfPathName:        UInt16;                                    {   --> length of packed pathName structure }
  3365.     END;
  3366.  
  3367. {
  3368. dNodeNumber in the DNodeNumber field will be mapped to the cooresponding
  3369. pathName and returned in the PackedPathName field.
  3370. lengthOfPathName is to be set the length of pathName structure.
  3371. If length of PackedPathName is larger then the lengthOfPathName, kOCEMoreData
  3372. OSErr will be returned.
  3373. }
  3374. {
  3375. GetLocalNetworkSpec:
  3376. This call will return the Local NetworkSpec. Client should supply
  3377. an RString big enough to hold the NetworkSpec.
  3378. }
  3379.     DirGetLocalNetworkSpecPBPtr = ^DirGetLocalNetworkSpecPB;
  3380.     DirGetLocalNetworkSpecPB = RECORD
  3381.         qLink:                    Ptr;
  3382.         reserved1:                LONGINT;
  3383.         reserved2:                LONGINT;
  3384.         ioCompletion:            DirIOCompletionUPP;
  3385.         ioResult:                OSErr;
  3386.         saveA5:                    UInt32;
  3387.         reqCode:                INTEGER;
  3388.         reserved:                ARRAY [0..1] OF LONGINT;
  3389.         serverHint:                AddrBlock;
  3390.         dsRefNum:                INTEGER;
  3391.         callID:                    UInt32;
  3392.         identity:                AuthIdentity;
  3393.         gReserved1:                LONGINT;
  3394.         gReserved2:                LONGINT;
  3395.         gReserved3:                LONGINT;
  3396.         clientData:                LONGINT;
  3397.         directoryName:            DirectoryNamePtr;                        {   --> catalog name  }
  3398.         discriminator:            DirDiscriminator;                        {   --> discriminator  }
  3399.         networkSpec:            NetworkSpecPtr;                            {  <--  NetworkSpec  }
  3400.     END;
  3401.  
  3402. {
  3403. PathName in the path field must be set to nil. internetName should be large
  3404. enough to hold the internetName. InterNetname returned indicates path finder's
  3405. local internet (configured by administrator).
  3406. }
  3407. {
  3408. GetDNodeInfo:
  3409. This call will return the information (internetName and descriptor)
  3410. for the given RLI of a DNode.
  3411. }
  3412.     DirGetDNodeInfoPBPtr = ^DirGetDNodeInfoPB;
  3413.     DirGetDNodeInfoPB = RECORD
  3414.         qLink:                    Ptr;
  3415.         reserved1:                LONGINT;
  3416.         reserved2:                LONGINT;
  3417.         ioCompletion:            DirIOCompletionUPP;
  3418.         ioResult:                OSErr;
  3419.         saveA5:                    UInt32;
  3420.         reqCode:                INTEGER;
  3421.         reserved:                ARRAY [0..1] OF LONGINT;
  3422.         serverHint:                AddrBlock;
  3423.         dsRefNum:                INTEGER;
  3424.         callID:                    UInt32;
  3425.         identity:                AuthIdentity;
  3426.         gReserved1:                LONGINT;
  3427.         gReserved2:                LONGINT;
  3428.         gReserved3:                LONGINT;
  3429.         clientData:                LONGINT;
  3430.         pRLI:                    PackedRLIPtr;                            {   --> packed RLI whose info is requested  }
  3431.         descriptor:                DirNodeKind;                            {  <--  dNode descriptor  }
  3432.         networkSpec:            NetworkSpecPtr;                            {  <--  cluster's networkSpec if kIsCluster  }
  3433.     END;
  3434.  
  3435. {
  3436. If DnodeNumber is set to a non zero value, path should be set to nil.
  3437. if DnodeNumber is set to zero, pathName should point to a packed path name.
  3438. internetName should be large enough to hold
  3439. the internetName. (If the internetName is same as the one got by
  3440. GetLocalInternetName call, it indicates cluster is reachable  without
  3441. forwarders, --> Tell me if I am wrong)
  3442. }
  3443.  
  3444. {
  3445. DirCreatePersonalDirectory:
  3446. A new  personal catalog can be created by specifying an FSSpec for
  3447. the file. If a file already exists dupFNErr will be returned. This call is
  3448. supported 'synchronous' mode only.
  3449. }
  3450.     DirCreatePersonalDirectoryPBPtr = ^DirCreatePersonalDirectoryPB;
  3451.     DirCreatePersonalDirectoryPB = RECORD
  3452.         qLink:                    Ptr;
  3453.         reserved1:                LONGINT;
  3454.         reserved2:                LONGINT;
  3455.         ioCompletion:            DirIOCompletionUPP;
  3456.         ioResult:                OSErr;
  3457.         saveA5:                    UInt32;
  3458.         reqCode:                INTEGER;
  3459.         reserved:                ARRAY [0..1] OF LONGINT;
  3460.         serverHint:                AddrBlock;
  3461.         dsRefNum:                INTEGER;
  3462.         callID:                    UInt32;
  3463.         identity:                AuthIdentity;
  3464.         gReserved1:                LONGINT;
  3465.         gReserved2:                LONGINT;
  3466.         gReserved3:                LONGINT;
  3467.         clientData:                LONGINT;
  3468.         fsSpec:                    FSSpecPtr;                                {   --> FSSpec for the Personal Catalog  }
  3469.         fdType:                    OSType;                                    {   --> file type for the Personal Catalog  }
  3470.         fdCreator:                OSType;                                    {   --> file creator for the Personal Catalog  }
  3471.     END;
  3472.  
  3473. {
  3474. DirOpenPersonalDirectory:
  3475. An existing personal catalog can be opened using this call.
  3476. User can specify the personal catalog by FSSpec for the AddressBook file.
  3477. 'accessRequested' field specifies open permissions. 'fsRdPerm'  & 'fsRdWrPerm'
  3478. are the only accepted open modes for the address book.
  3479. When the call completes successfully, a dsRefNum will be returned. The 'dsRefNum'
  3480. field is in the DSParamBlockHeader. In addittion 'accessGranted' indicates
  3481. actual permission with personal catalog is opened and 'features' indicate the capabilty flags
  3482. associated with the personal catalog.
  3483. This call is supported 'synchronous' mode only.
  3484. }
  3485.  
  3486.     DirOpenPersonalDirectoryPBPtr = ^DirOpenPersonalDirectoryPB;
  3487.     DirOpenPersonalDirectoryPB = RECORD
  3488.         qLink:                    Ptr;
  3489.         reserved1:                LONGINT;
  3490.         reserved2:                LONGINT;
  3491.         ioCompletion:            DirIOCompletionUPP;
  3492.         ioResult:                OSErr;
  3493.         saveA5:                    UInt32;
  3494.         reqCode:                INTEGER;
  3495.         reserved:                ARRAY [0..1] OF LONGINT;
  3496.         serverHint:                AddrBlock;
  3497.         dsRefNum:                INTEGER;
  3498.         callID:                    UInt32;
  3499.         identity:                AuthIdentity;
  3500.         gReserved1:                LONGINT;
  3501.         gReserved2:                LONGINT;
  3502.         gReserved3:                LONGINT;
  3503.         clientData:                LONGINT;
  3504.         fsSpec:                    FSSpecPtr;                                {   --> Open an existing Personal Catalog  }
  3505.         accessRequested:        SInt8;                                    {   --> Open: permissions Requested(byte) }
  3506.         accessGranted:            SInt8;                                    {   <-- Open: permissions (byte) (Granted) }
  3507.         features:                DirGestalt;                                {  <--  features for Personal Catalog  }
  3508.     END;
  3509.  
  3510. {
  3511. DirClosePersonalDirectory: This call lets a client close AddressBook opened by DirOpenPersonalDirectory.
  3512. The Personal Catalog specified by the 'dsRefNum' will be closed.
  3513. This call is supported 'synchronous' mode only.
  3514. }
  3515.     DirClosePersonalDirectoryPBPtr = ^DirClosePersonalDirectoryPB;
  3516.     DirClosePersonalDirectoryPB = RECORD
  3517.         qLink:                    Ptr;
  3518.         reserved1:                LONGINT;
  3519.         reserved2:                LONGINT;
  3520.         ioCompletion:            DirIOCompletionUPP;
  3521.         ioResult:                OSErr;
  3522.         saveA5:                    UInt32;
  3523.         reqCode:                INTEGER;
  3524.         reserved:                ARRAY [0..1] OF LONGINT;
  3525.         serverHint:                AddrBlock;
  3526.         dsRefNum:                INTEGER;
  3527.         callID:                    UInt32;
  3528.         identity:                AuthIdentity;
  3529.         gReserved1:                LONGINT;
  3530.         gReserved2:                LONGINT;
  3531.         gReserved3:                LONGINT;
  3532.         clientData:                LONGINT;
  3533.     END;
  3534.  
  3535.  
  3536. {
  3537. DirMakePersonalDirectoryRLI: With this call a client can make an RLI
  3538. for a Personal Catalog opened by DirOpenPersonalDirectory Call.
  3539. A packed RLI is created for the Personal Catalog specified by the 'dsRefNum'.
  3540. If a client has a need to make the AddressBook reference to persistent
  3541. acrross boots it should make use of this call. In the current implementaion
  3542. PackedRLI has an embeeded System7.0 'alias'. If in later time
  3543. If client has a need to make reference to the AddressBook, it must use
  3544. ADAPLibrary call 'DUExtractAlias' and resole the 'alias' to 'FSSpec' and
  3545. make DirOpenPersonalDirectory call to get a 'dsRefNum'.
  3546.   'fromFSSpec'            FSPecPtr from which relative alias to be created. If nil,
  3547.                         absolute alias is created.
  3548.  'pRLIBufferSize' indicates the size of buffer pointed by 'pRLI'
  3549.  'pRLISize'    indicates the actual length of 'pRLI'. If the call
  3550.                         fails with 'kOCEMoreData' error a client can reissue
  3551.                     this call with a larger buffer of this length.
  3552.   'pRLI' is pointer to the buffer in which 'PackedRLI' is
  3553.   returned.
  3554. This call is supported in 'synchronous' mode only.
  3555. }
  3556.     DirMakePersonalDirectoryRLIPBPtr = ^DirMakePersonalDirectoryRLIPB;
  3557.     DirMakePersonalDirectoryRLIPB = RECORD
  3558.         qLink:                    Ptr;
  3559.         reserved1:                LONGINT;
  3560.         reserved2:                LONGINT;
  3561.         ioCompletion:            DirIOCompletionUPP;
  3562.         ioResult:                OSErr;
  3563.         saveA5:                    UInt32;
  3564.         reqCode:                INTEGER;
  3565.         reserved:                ARRAY [0..1] OF LONGINT;
  3566.         serverHint:                AddrBlock;
  3567.         dsRefNum:                INTEGER;
  3568.         callID:                    UInt32;
  3569.         identity:                AuthIdentity;
  3570.         gReserved1:                LONGINT;
  3571.         gReserved2:                LONGINT;
  3572.         gReserved3:                LONGINT;
  3573.         clientData:                LONGINT;
  3574.         fromFSSpec:                FSSpecPtr;                                {   --> FSSpec for creating relative alia  }
  3575.         pRLIBufferSize:            UInt16;                                    {   --> Length of 'pRLI' buffer  }
  3576.         pRLISize:                UInt16;                                    {  <--  Length of actual 'pRLI'  }
  3577.         pRLI:                    PackedRLIPtr;                            {  <--  pRLI for the specified AddressBook  }
  3578.     END;
  3579.  
  3580.  
  3581. {****************************************************************************
  3582. The calls described below apply only for CSAM Drivers:
  3583.  
  3584. The following three calls provide capability to Install/Remove a CSAM at RunTime.
  3585.     DirAddDSAM
  3586.     DirRemoveDSAM
  3587.     DirInstantiateDSAM
  3588.  
  3589. The following two calls provide capability to Install/Remove a CSAM Catalog at RunTime.
  3590.     DirAddDSAMDirectory
  3591.     DirRemoveDirectory
  3592.  
  3593. DirGetDirectoryIcon call is used by clients to get any special icon associated
  3594. with a CSAM catalog.
  3595.  
  3596. ****************************************************************************}
  3597.  
  3598. {
  3599. DirAddDSAM: This call can be used to inorm the availability of a CSAM file
  3600. after discovering the CSAM file.
  3601.     dsamName -> is generic CSAM name e.g. Untitled X.500 directory
  3602.     dsamSignature -> could be generic CSAM kind e.g. 'X500'.
  3603.     fsSpec -> is the FileSpec for the file containing CSAM resources.
  3604. If the call is successfull 'DSAMRecordCID' will be returned. If the
  3605. call returns 'daDSAMRecordCIDExists', record was already there and
  3606. 'dsamRecordCID' will be returned.
  3607. This call can be done only in synchronous mode.
  3608. }
  3609.     DirAddDSAMPBPtr = ^DirAddDSAMPB;
  3610.     DirAddDSAMPB = RECORD
  3611.         qLink:                    Ptr;
  3612.         reserved1:                LONGINT;
  3613.         reserved2:                LONGINT;
  3614.         ioCompletion:            DirIOCompletionUPP;
  3615.         ioResult:                OSErr;
  3616.         saveA5:                    UInt32;
  3617.         reqCode:                INTEGER;
  3618.         reserved:                ARRAY [0..1] OF LONGINT;
  3619.         serverHint:                AddrBlock;
  3620.         dsRefNum:                INTEGER;
  3621.         callID:                    UInt32;
  3622.         identity:                AuthIdentity;
  3623.         gReserved1:                LONGINT;
  3624.         gReserved2:                LONGINT;
  3625.         gReserved3:                LONGINT;
  3626.         clientData:                LONGINT;
  3627.         dsamRecordCID:            CreationID;                                {  <--  CreationID for the CSAM record  }
  3628.         dsamName:                RStringPtr;                                {   --> CSAM name  }
  3629.         dsamKind:                OCEDirectoryKind;                        {   --> CSAM kind  }
  3630.         fsSpec:                    FSSpecPtr;                                {   --> FSSpec for the file containing CSAM  }
  3631.     END;
  3632.  
  3633. {
  3634. DirInstantiateDSAM: This call should be used by the CSAM driver in response
  3635. Driver Open call to indicate the toolbox about the availability of the CSAM.
  3636.     dsamName -> is generic CSAM name e.g. Untitled X.500 directory
  3637.     dsamKind -> could be generic CSAM kind e.g. 'X500'.
  3638.     dsamData -> pointer to private DSAMData. This will be paased back to the CSAM
  3639.     when the CSAM functions (DSAMDirProc,DSAMDirParseProc, DSAMAuthProc) are called.
  3640.     CSAM should already be setup using DirAddDSAM call.
  3641.     DSAMDirProc -> This procedure will be called when  any catalog service
  3642.     call intended for the CSAM (other then parse calls)
  3643.     DSAMDirParseProc -> This procedure will be called when any of the parse calls
  3644.     are called.
  3645.     DSAMAuthProc -> This procedure will be called when any of the Authentication Calls
  3646.     are made to the CSAM. If the CSAM does not support authentication, this can be nil.
  3647. This call can be done only in synchronous mode.
  3648. }
  3649. {$IFC TYPED_FUNCTION_POINTERS}
  3650.     DSAMDirProcPtr = FUNCTION(dsamData: UNIV Ptr; paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  3651. {$ELSEC}
  3652.     DSAMDirProcPtr = ProcPtr;
  3653. {$ENDC}
  3654.  
  3655.     DSAMDirUPP = UniversalProcPtr;
  3656.     DSAMDirProc                            = DSAMDirUPP;
  3657. {$IFC TYPED_FUNCTION_POINTERS}
  3658.     DSAMDirParseProcPtr = FUNCTION(dsamData: UNIV Ptr; paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  3659. {$ELSEC}
  3660.     DSAMDirParseProcPtr = ProcPtr;
  3661. {$ENDC}
  3662.  
  3663.     DSAMDirParseUPP = UniversalProcPtr;
  3664.     DSAMDirParseProc                    = DSAMDirParseUPP;
  3665. {$IFC TYPED_FUNCTION_POINTERS}
  3666.     DSAMAuthProcPtr = FUNCTION(dsamData: UNIV Ptr; pb: AuthParamBlockPtr; async: BOOLEAN): OSErr;
  3667. {$ELSEC}
  3668.     DSAMAuthProcPtr = ProcPtr;
  3669. {$ENDC}
  3670.  
  3671.     DSAMAuthUPP = UniversalProcPtr;
  3672.     DSAMAuthProc                        = DSAMAuthUPP;
  3673.     DirInstantiateDSAMPBPtr = ^DirInstantiateDSAMPB;
  3674.     DirInstantiateDSAMPB = RECORD
  3675.         qLink:                    Ptr;
  3676.         reserved1:                LONGINT;
  3677.         reserved2:                LONGINT;
  3678.         ioCompletion:            DirIOCompletionUPP;
  3679.         ioResult:                OSErr;
  3680.         saveA5:                    UInt32;
  3681.         reqCode:                INTEGER;
  3682.         reserved:                ARRAY [0..1] OF LONGINT;
  3683.         serverHint:                AddrBlock;
  3684.         dsRefNum:                INTEGER;
  3685.         callID:                    UInt32;
  3686.         identity:                AuthIdentity;
  3687.         gReserved1:                LONGINT;
  3688.         gReserved2:                LONGINT;
  3689.         gReserved3:                LONGINT;
  3690.         clientData:                LONGINT;
  3691.         dsamName:                RStringPtr;                                {   --> dsamName name  }
  3692.         dsamKind:                OCEDirectoryKind;                        {   --> DSAMKind  }
  3693.         dsamData:                Ptr;                                    {   --> dsamData   }
  3694.         dsamDirProc:            DSAMDirUPP;                                {   --> of type DSAMDirProc: for catalog service calls  }
  3695.         dsamDirParseProc:        DSAMDirParseUPP;                        {   --> of type DSAMDirParseProc: for catalog service parse calls  }
  3696.         dsamAuthProc:            DSAMAuthUPP;                            {   --> of type DSAMAuthProc: for authetication service calls  }
  3697.     END;
  3698.  
  3699.  
  3700. {
  3701. DirRemoveDSAM: This call can be used to remove  a CSAM file from the OCE Setup.
  3702.     dsamRecordCID -> is the creationID of the CSAM record.
  3703. This call can be made only in synchronous mode.
  3704. }
  3705.     DirRemoveDSAMPBPtr = ^DirRemoveDSAMPB;
  3706.     DirRemoveDSAMPB = RECORD
  3707.         qLink:                    Ptr;
  3708.         reserved1:                LONGINT;
  3709.         reserved2:                LONGINT;
  3710.         ioCompletion:            DirIOCompletionUPP;
  3711.         ioResult:                OSErr;
  3712.         saveA5:                    UInt32;
  3713.         reqCode:                INTEGER;
  3714.         reserved:                ARRAY [0..1] OF LONGINT;
  3715.         serverHint:                AddrBlock;
  3716.         dsRefNum:                INTEGER;
  3717.         callID:                    UInt32;
  3718.         identity:                AuthIdentity;
  3719.         gReserved1:                LONGINT;
  3720.         gReserved2:                LONGINT;
  3721.         gReserved3:                LONGINT;
  3722.         clientData:                LONGINT;
  3723.         dsamRecordCID:            CreationID;                                {  <--  CreationID for the CSAM record  }
  3724.     END;
  3725.  
  3726.  
  3727. {
  3728. DirAddDSAMDirectory: This call can be used to inorm the availability of a CSAM catalog.
  3729.     dsamRecordCID ->  recordID for the CSAM serving this catalog
  3730.     directoryName ->  name of the catalog
  3731.     discriminator -> discriminator for the catalog
  3732.     directoryRecordCID -> If the call is successful, creationID for the record will
  3733.                             be returned.
  3734. }
  3735.     DirAddDSAMDirectoryPBPtr = ^DirAddDSAMDirectoryPB;
  3736.     DirAddDSAMDirectoryPB = RECORD
  3737.         qLink:                    Ptr;
  3738.         reserved1:                LONGINT;
  3739.         reserved2:                LONGINT;
  3740.         ioCompletion:            DirIOCompletionUPP;
  3741.         ioResult:                OSErr;
  3742.         saveA5:                    UInt32;
  3743.         reqCode:                INTEGER;
  3744.         reserved:                ARRAY [0..1] OF LONGINT;
  3745.         serverHint:                AddrBlock;
  3746.         dsRefNum:                INTEGER;
  3747.         callID:                    UInt32;
  3748.         identity:                AuthIdentity;
  3749.         gReserved1:                LONGINT;
  3750.         gReserved2:                LONGINT;
  3751.         gReserved3:                LONGINT;
  3752.         clientData:                LONGINT;
  3753.         dsamRecordCID:            CreationID;                                {   --> CreationID for the CSAM record  }
  3754.         directoryName:            DirectoryNamePtr;                        {   --> catalog name  }
  3755.         discriminator:            DirDiscriminator;                        {   --> catalog discriminator  }
  3756.         features:                DirGestalt;                                {   --> capabilty flags for the catalog  }
  3757.         directoryRecordCID:        CreationID;                                {  <--  creationID for the catalog record  }
  3758.     END;
  3759.  
  3760. {
  3761. DirRemoveDirectory: This call can be used to inform the toolbox that
  3762. catalog specified by 'directoryRecordCID'
  3763. }
  3764.     DirRemoveDirectoryPBPtr = ^DirRemoveDirectoryPB;
  3765.     DirRemoveDirectoryPB = RECORD
  3766.         qLink:                    Ptr;
  3767.         reserved1:                LONGINT;
  3768.         reserved2:                LONGINT;
  3769.         ioCompletion:            DirIOCompletionUPP;
  3770.         ioResult:                OSErr;
  3771.         saveA5:                    UInt32;
  3772.         reqCode:                INTEGER;
  3773.         reserved:                ARRAY [0..1] OF LONGINT;
  3774.         serverHint:                AddrBlock;
  3775.         dsRefNum:                INTEGER;
  3776.         callID:                    UInt32;
  3777.         identity:                AuthIdentity;
  3778.         gReserved1:                LONGINT;
  3779.         gReserved2:                LONGINT;
  3780.         gReserved3:                LONGINT;
  3781.         clientData:                LONGINT;
  3782.         directoryRecordCID:        CreationID;                                {   --> creationID for the catalog record  }
  3783.     END;
  3784.  
  3785. {
  3786.  * DSGetExtendedDirectoriesInfo::  This call can be used to get
  3787.  * the information of various foreign catalogs supported.
  3788.  * Typically a DE Template  may make this call to create a
  3789.  * Address template or a Gateway may make this call to findout
  3790.  * catalog name space in which MSAM may would support. 
  3791.  * Client will supply a buffer pointed by 'bufferPtr' of size 'bufferLength'. 
  3792.  * When the call completes with 'daMoreData' error, client can examine 'totalEntries'
  3793.  * returned and reissue the call with increaing buffer.
  3794.  * Toolbox will findout the private information of each of the Foreign Catalogs
  3795.  * by polling CSAM's, Gateways, and MnMServers. The Information returned
  3796.  * for each catalog will be packed in the format: 
  3797.  * typedef struct EachDirectoryData (
  3798.  *  PackedRLI                        pRLI;           //  packed RLI for the catalog
  3799.  *  OSType                            entnType;        //  Entn Type
  3800.  *  long                            hasMailSlot;   //  If this catalog has mail slot this will be 1 otherwise zero
  3801.  *    ProtoRString                    RealName;      //  Packed RString for Real Name (padded to even boundary) 
  3802.  *    ProtoRString                    comment;       //  Packed RString holding any comment for Display (padded to even boundary)
  3803.  *    long                            length;        //  data length
  3804.  *    char                            data[length];  //  data padded to even boundary
  3805.  * );
  3806.  *
  3807.  *
  3808.  *
  3809.  * typedef struct myData (
  3810.  *      EachDirectoryData    data[numberOfEntries];    // data packed in the above format
  3811.  *    );
  3812.  *
  3813.  }
  3814.     DirGetExtendedDirectoriesInfoPBPtr = ^DirGetExtendedDirectoriesInfoPB;
  3815.     DirGetExtendedDirectoriesInfoPB = RECORD
  3816.         qLink:                    Ptr;
  3817.         reserved1:                LONGINT;
  3818.         reserved2:                LONGINT;
  3819.         ioCompletion:            DirIOCompletionUPP;
  3820.         ioResult:                OSErr;
  3821.         saveA5:                    UInt32;
  3822.         reqCode:                INTEGER;
  3823.         reserved:                ARRAY [0..1] OF LONGINT;
  3824.         serverHint:                AddrBlock;
  3825.         dsRefNum:                INTEGER;
  3826.         callID:                    UInt32;
  3827.         identity:                AuthIdentity;
  3828.         gReserved1:                LONGINT;
  3829.         gReserved2:                LONGINT;
  3830.         gReserved3:                LONGINT;
  3831.         clientData:                LONGINT;
  3832.         buffer:                    Ptr;                                    {   --> Pointer to a buufer where data will be returned  }
  3833.         bufferSize:                UInt32;                                    {   --> Length of the buffer, Length of actual data will be returned here  }
  3834.         totalEntries:            UInt32;                                    {  <--  Total Number of Catalogs found  }
  3835.         actualEntries:            UInt32;                                    {  <--  Total Number of Catalogs entries returned  }
  3836.     END;
  3837.  
  3838. {
  3839. DirGetDirectoryIconPB: With this call a client can find out about
  3840. the icons supported by the Catalog.
  3841. Both ADAP and Personal Catalog will not support this call for now.
  3842. A CSAM can support a call so that DE Extension can use this
  3843. call to find appropriate Icons.
  3844.  
  3845. Returns kOCEBufferTooSmall if icon is too small, but will update iconSize.
  3846. }
  3847.     DirGetDirectoryIconPBPtr = ^DirGetDirectoryIconPB;
  3848.     DirGetDirectoryIconPB = RECORD
  3849.         qLink:                    Ptr;
  3850.         reserved1:                LONGINT;
  3851.         reserved2:                LONGINT;
  3852.         ioCompletion:            DirIOCompletionUPP;
  3853.         ioResult:                OSErr;
  3854.         saveA5:                    UInt32;
  3855.         reqCode:                INTEGER;
  3856.         reserved:                ARRAY [0..1] OF LONGINT;
  3857.         serverHint:                AddrBlock;
  3858.         dsRefNum:                INTEGER;
  3859.         callID:                    UInt32;
  3860.         identity:                AuthIdentity;
  3861.         gReserved1:                LONGINT;
  3862.         gReserved2:                LONGINT;
  3863.         gReserved3:                LONGINT;
  3864.         clientData:                LONGINT;
  3865.         pRLI:                    PackedRLIPtr;                            {   --> packed RLI for the catalog  }
  3866.         iconType:                OSType;                                    {   --> Type of Icon requested  }
  3867.         iconBuffer:                Ptr;                                    {   --> Buffer to hold Icon Data  }
  3868.         bufferSize:                UInt32;                                    {   <-> size of buffer to hold icon data  }
  3869.     END;
  3870.  
  3871. {
  3872. DirGetOCESetupRefNum: This call will return 'dsRefnum' for the OCE Setup Personal Catalog
  3873. and oceSetupRecordCID for the oceSetup Record.
  3874. Clients interested in manipulating OCE Setup Personal Catalog directly should
  3875. make this call to get 'dsRefNum'.
  3876. 'dsRefNum' will be returned in the standard field in the DirParamHeader.
  3877. }
  3878.     DirGetOCESetupRefNumPBPtr = ^DirGetOCESetupRefNumPB;
  3879.     DirGetOCESetupRefNumPB = RECORD
  3880.         qLink:                    Ptr;
  3881.         reserved1:                LONGINT;
  3882.         reserved2:                LONGINT;
  3883.         ioCompletion:            DirIOCompletionUPP;
  3884.         ioResult:                OSErr;
  3885.         saveA5:                    UInt32;
  3886.         reqCode:                INTEGER;
  3887.         reserved:                ARRAY [0..1] OF LONGINT;
  3888.         serverHint:                AddrBlock;
  3889.         dsRefNum:                INTEGER;
  3890.         callID:                    UInt32;
  3891.         identity:                AuthIdentity;
  3892.         gReserved1:                LONGINT;
  3893.         gReserved2:                LONGINT;
  3894.         gReserved3:                LONGINT;
  3895.         clientData:                LONGINT;
  3896.         oceSetupRecordCID:        CreationID;                                {  --> creationID for the catalog record  }
  3897.     END;
  3898.  
  3899.  
  3900. {***************************************************************************}
  3901. { Catalog and Authentication control blocks and operation definitions }
  3902.     AuthParamBlock = RECORD
  3903.         CASE INTEGER OF
  3904.         0: (
  3905.             qLink:                Ptr;
  3906.             reserved1:            LONGINT;
  3907.             reserved2:            LONGINT;
  3908.             ioCompletion:        AuthIOCompletionUPP;
  3909.             ioResult:            OSErr;
  3910.             saveA5:                UInt32;
  3911.             reqCode:            INTEGER;
  3912.             reserved:            ARRAY [0..1] OF LONGINT;
  3913.             serverHint:            AddrBlock;
  3914.             dsRefNum:            INTEGER;
  3915.             callID:                UInt32;
  3916.             identity:            AuthIdentity;
  3917.             gReserved1:            LONGINT;
  3918.             gReserved2:            LONGINT;
  3919.             gReserved3:            LONGINT;
  3920.             clientData:            LONGINT;
  3921.            );
  3922.         1: (
  3923.             bindIdentityPB:        AuthBindSpecificIdentityPB;
  3924.             );
  3925.         2: (
  3926.             unbindIdentityPB:    AuthUnbindSpecificIdentityPB;
  3927.             );
  3928.         3: (
  3929.             resolveCreationIDPB: AuthResolveCreationIDPB;
  3930.             );
  3931.         4: (
  3932.             getIdentityInfoPB:    AuthGetSpecificIdentityInfoPB;
  3933.             );
  3934.         5: (
  3935.             addKeyPB:            AuthAddKeyPB;
  3936.             );
  3937.         6: (
  3938.             changeKeyPB:        AuthChangeKeyPB;
  3939.             );
  3940.         7: (
  3941.             deleteKeyPB:        AuthDeleteKeyPB;
  3942.             );
  3943.         8: (
  3944.             passwordToKeyPB:    AuthPasswordToKeyPB;
  3945.             );
  3946.         9: (
  3947.             getCredentialsPB:    AuthGetCredentialsPB;
  3948.             );
  3949.         10: (
  3950.             decryptCredentialsPB: AuthDecryptCredentialsPB;
  3951.             );
  3952.         11: (
  3953.             makeChallengePB:    AuthMakeChallengePB;
  3954.             );
  3955.         12: (
  3956.             makeReplyPB:        AuthMakeReplyPB;
  3957.             );
  3958.         13: (
  3959.             verifyReplyPB:        AuthVerifyReplyPB;
  3960.             );
  3961.         14: (
  3962.             getUTCTimePB:        AuthGetUTCTimePB;
  3963.             );
  3964.         15: (
  3965.             makeProxyPB:        AuthMakeProxyPB;
  3966.             );
  3967.         16: (
  3968.             tradeProxyForCredentialsPB: AuthTradeProxyForCredentialsPB;
  3969.             );
  3970.         17: (
  3971.             getLocalIdentityPB:    AuthGetLocalIdentityPB;
  3972.             );
  3973.         18: (
  3974.             unLockLocalIdentityPB: AuthUnlockLocalIdentityPB;
  3975.             );
  3976.         19: (
  3977.             lockLocalIdentityPB: AuthLockLocalIdentityPB;
  3978.             );
  3979.         20: (
  3980.             localIdentityQInstallPB: AuthAddToLocalIdentityQueuePB;
  3981.             );
  3982.         21: (
  3983.             localIdentityQRemovePB: AuthRemoveFromLocalIdentityQueuePB;
  3984.             );
  3985.         22: (
  3986.             setupLocalIdentityPB: AuthSetupLocalIdentityPB;
  3987.             );
  3988.         23: (
  3989.             changeLocalIdentityPB: AuthChangeLocalIdentityPB;
  3990.             );
  3991.         24: (
  3992.             removeLocalIdentityPB: AuthRemoveLocalIdentityPB;
  3993.             );
  3994.         25: (
  3995.             setupDirectoryIdentityPB: OCESetupAddDirectoryInfoPB;
  3996.             );
  3997.         26: (
  3998.             changeDirectoryIdentityPB: OCESetupChangeDirectoryInfoPB;
  3999.             );
  4000.         27: (
  4001.             removeDirectoryIdentityPB: OCESetupRemoveDirectoryInfoPB;
  4002.             );
  4003.         28: (
  4004.             getDirectoryIdentityInfoPB: OCESetupGetDirectoryInfoPB;
  4005.             );
  4006.     END;
  4007.  
  4008.     DirParamBlock = RECORD
  4009.         CASE INTEGER OF
  4010.         0: (
  4011.             qLink:                Ptr;
  4012.             reserved1:            LONGINT;
  4013.             reserved2:            LONGINT;
  4014.             ioCompletion:        DirIOCompletionUPP;
  4015.             ioResult:            OSErr;
  4016.             saveA5:                UInt32;
  4017.             reqCode:            INTEGER;
  4018.             reserved:            ARRAY [0..1] OF LONGINT;
  4019.             serverHint:            AddrBlock;
  4020.             dsRefNum:            INTEGER;
  4021.             callID:                UInt32;
  4022.             identity:            AuthIdentity;
  4023.             gReserved1:            LONGINT;
  4024.             gReserved2:            LONGINT;
  4025.             gReserved3:            LONGINT;
  4026.             clientData:            LONGINT;
  4027.            );
  4028.         1: (
  4029.             addRecordPB:        DirAddRecordPB;
  4030.             );
  4031.         2: (
  4032.             deleteRecordPB:        DirDeleteRecordPB;
  4033.             );
  4034.         3: (
  4035.             enumerateGetPB:        DirEnumerateGetPB;
  4036.             );
  4037.         4: (
  4038.             enumerateParsePB:    DirEnumerateParsePB;
  4039.             );
  4040.         5: (
  4041.             findRecordGetPB:    DirFindRecordGetPB;
  4042.             );
  4043.         6: (
  4044.             findRecordParsePB:    DirFindRecordParsePB;
  4045.             );
  4046.         7: (
  4047.             lookupGetPB:        DirLookupGetPB;
  4048.             );
  4049.         8: (
  4050.             lookupParsePB:        DirLookupParsePB;
  4051.             );
  4052.         9: (
  4053.             addAttributeValuePB: DirAddAttributeValuePB;
  4054.             );
  4055.         10: (
  4056.             deleteAttributeTypePB: DirDeleteAttributeTypePB;
  4057.             );
  4058.         11: (
  4059.             deleteAttributeValuePB: DirDeleteAttributeValuePB;
  4060.             );
  4061.         12: (
  4062.             changeAttributeValuePB: DirChangeAttributeValuePB;
  4063.             );
  4064.         13: (
  4065.             verifyAttributeValuePB: DirVerifyAttributeValuePB;
  4066.             );
  4067.         14: (
  4068.             findValuePB:        DirFindValuePB;
  4069.             );
  4070.         15: (
  4071.             enumeratePseudonymGetPB: DirEnumeratePseudonymGetPB;
  4072.             );
  4073.         16: (
  4074.             enumeratePseudonymParsePB: DirEnumeratePseudonymParsePB;
  4075.             );
  4076.         17: (
  4077.             addPseudonymPB:        DirAddPseudonymPB;
  4078.             );
  4079.         18: (
  4080.             deletePseudonymPB:    DirDeletePseudonymPB;
  4081.             );
  4082.         19: (
  4083.             addAliasPB:            DirAddAliasPB;
  4084.             );
  4085.         20: (
  4086.             enumerateAttributeTypesGetPB: DirEnumerateAttributeTypesGetPB;
  4087.             );
  4088.         21: (
  4089.             enumerateAttributeTypesParsePB: DirEnumerateAttributeTypesParsePB;
  4090.             );
  4091.         22: (
  4092.             getNameAndTypePB:    DirGetNameAndTypePB;
  4093.             );
  4094.         23: (
  4095.             setNameAndTypePB:    DirSetNameAndTypePB;
  4096.             );
  4097.         24: (
  4098.             getRecordMetaInfoPB: DirGetRecordMetaInfoPB;
  4099.             );
  4100.         25: (
  4101.             getDNodeMetaInfoPB:    DirGetDNodeMetaInfoPB;
  4102.             );
  4103.         26: (
  4104.             getDirectoryInfoPB:    DirGetDirectoryInfoPB;
  4105.             );
  4106.         27: (
  4107.             getDNodeAccessControlGetPB: DirGetDNodeAccessControlGetPB;
  4108.             );
  4109.         28: (
  4110.             getDNodeAccessControlParsePB: DirGetDNodeAccessControlParsePB;
  4111.             );
  4112.         29: (
  4113.             getRecordAccessControlGetPB: DirGetRecordAccessControlGetPB;
  4114.             );
  4115.         30: (
  4116.             getRecordAccessControlParsePB: DirGetRecordAccessControlParsePB;
  4117.             );
  4118.         31: (
  4119.             getAttributeAccessControlGetPB: DirGetAttributeAccessControlGetPB;
  4120.             );
  4121.         32: (
  4122.             getAttributeAccessControlParsePB: DirGetAttributeAccessControlParsePB;
  4123.             );
  4124.         33: (
  4125.             enumerateDirectoriesGetPB: DirEnumerateDirectoriesGetPB;
  4126.             );
  4127.         34: (
  4128.             enumerateDirectoriesParsePB: DirEnumerateDirectoriesParsePB;
  4129.             );
  4130.         35: (
  4131.             addADAPDirectoryPB:    DirAddADAPDirectoryPB;
  4132.             );
  4133.         36: (
  4134.             removeDirectoryPB:    DirRemoveDirectoryPB;
  4135.             );
  4136.         37: (
  4137.             netSearchADAPDirectoriesGetPB: DirNetSearchADAPDirectoriesGetPB;
  4138.             );
  4139.         38: (
  4140.             netSearchADAPDirectoriesParsePB: DirNetSearchADAPDirectoriesParsePB;
  4141.             );
  4142.         39: (
  4143.             findADAPDirectoryByNetSearchPB: DirFindADAPDirectoryByNetSearchPB;
  4144.             );
  4145.         40: (
  4146.             mapDNodeNumberToPathNamePB: DirMapDNodeNumberToPathNamePB;
  4147.             );
  4148.         41: (
  4149.             mapPathNameToDNodeNumberPB: DirMapPathNameToDNodeNumberPB;
  4150.             );
  4151.         42: (
  4152.             getLocalNetworkSpecPB: DirGetLocalNetworkSpecPB;
  4153.             );
  4154.         43: (
  4155.             getDNodeInfoPB:        DirGetDNodeInfoPB;
  4156.             );
  4157.         44: (
  4158.             createPersonalDirectoryPB: DirCreatePersonalDirectoryPB;
  4159.             );
  4160.         45: (
  4161.             openPersonalDirectoryPB: DirOpenPersonalDirectoryPB;
  4162.             );
  4163.         46: (
  4164.             closePersonalDirectoryPB: DirClosePersonalDirectoryPB;
  4165.             );
  4166.         47: (
  4167.             makePersonalDirectoryRLIPB: DirMakePersonalDirectoryRLIPB;
  4168.             );
  4169.         48: (
  4170.             addDSAMPB:            DirAddDSAMPB;
  4171.             );
  4172.         49: (
  4173.             instantiateDSAMPB:    DirInstantiateDSAMPB;
  4174.             );
  4175.         50: (
  4176.             removeDSAMPB:        DirRemoveDSAMPB;
  4177.             );
  4178.         51: (
  4179.             addDSAMDirectoryPB:    DirAddDSAMDirectoryPB;
  4180.             );
  4181.         52: (
  4182.             getExtendedDirectoriesInfoPB: DirGetExtendedDirectoriesInfoPB;
  4183.             );
  4184.         53: (
  4185.             getDirectoryIconPB:    DirGetDirectoryIconPB;
  4186.             );
  4187.         54: (
  4188.             dirGetOCESetupRefNumPB: DirGetOCESetupRefNumPB;
  4189.             );
  4190.         55: (
  4191.             abortPB:            DirAbortPB;
  4192.             );
  4193.     END;
  4194.  
  4195.  
  4196. CONST
  4197.     uppAuthIOCompletionProcInfo = $00009802;
  4198.     uppNotificationProcInfo = $00003FD0;
  4199.     uppDirIOCompletionProcInfo = $00009802;
  4200.     uppForEachDirEnumSpecProcInfo = $000003D0;
  4201.     uppForEachRecordProcInfo = $00000FD0;
  4202.     uppForEachLookupRecordIDProcInfo = $000003D0;
  4203.     uppForEachAttrTypeLookupProcInfo = $00000FD0;
  4204.     uppForEachAttrValueProcInfo = $000003D0;
  4205.     uppForEachAttrTypeProcInfo = $000003D0;
  4206.     uppForEachRecordIDProcInfo = $000003D0;
  4207.     uppForEachDirectoryProcInfo = $00003FD0;
  4208.     uppForEachADAPDirectoryProcInfo = $0000FFD0;
  4209.     uppForEachDNodeAccessControlProcInfo = $0000FFD0;
  4210.     uppForEachRecordAccessControlProcInfo = $0000FFD0;
  4211.     uppForEachAttributeAccessControlProcInfo = $0000FFD0;
  4212.     uppDSAMDirProcInfo = $000007E0;
  4213.     uppDSAMDirParseProcInfo = $000007E0;
  4214.     uppDSAMAuthProcInfo = $000007E0;
  4215.  
  4216. PROCEDURE CallAuthIOCompletionProc(paramBlock: AuthParamBlockPtr; userRoutine: AuthIOCompletionUPP);
  4217.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4218.     {To be implemented:  Glue to move parameters into registers.}
  4219.     {$ENDC}
  4220.  
  4221. FUNCTION CallNotificationProc(clientData: LONGINT; callValue: AuthLocalIdentityOp; actionValue: AuthLocalIdentityLockAction; identity: LocalIdentity; userRoutine: NotificationUPP): BOOLEAN;
  4222.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4223.     INLINE $205F, $4E90;
  4224.     {$ENDC}
  4225.  
  4226. PROCEDURE CallDirIOCompletionProc(paramBlock: DirParamBlockPtr; userRoutine: DirIOCompletionUPP);
  4227.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4228.     {To be implemented:  Glue to move parameters into registers.}
  4229.     {$ENDC}
  4230.  
  4231. FUNCTION CallForEachDirEnumSpecProc(clientData: LONGINT; {CONST}VAR enumSpec: DirEnumSpec; userRoutine: ForEachDirEnumSpecUPP): BOOLEAN;
  4232.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4233.     INLINE $205F, $4E90;
  4234.     {$ENDC}
  4235.  
  4236. FUNCTION CallForEachRecordProc(clientData: LONGINT; {CONST}VAR enumSpec: DirEnumSpec; pRLI: PackedRLIPtr; userRoutine: ForEachRecordUPP): BOOLEAN;
  4237.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4238.     INLINE $205F, $4E90;
  4239.     {$ENDC}
  4240.  
  4241. FUNCTION CallForEachLookupRecordIDProc(clientData: LONGINT; {CONST}VAR recordID: RecordID; userRoutine: ForEachLookupRecordIDUPP): BOOLEAN;
  4242.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4243.     INLINE $205F, $4E90;
  4244.     {$ENDC}
  4245.  
  4246. FUNCTION CallForEachAttrTypeLookupProc(clientData: LONGINT; {CONST}VAR attrType: AttributeType; myAttrAccMask: AccessMask; userRoutine: ForEachAttrTypeLookupUPP): BOOLEAN;
  4247.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4248.     INLINE $205F, $4E90;
  4249.     {$ENDC}
  4250.  
  4251. FUNCTION CallForEachAttrValueProc(clientData: LONGINT; {CONST}VAR attribute: Attribute; userRoutine: ForEachAttrValueUPP): BOOLEAN;
  4252.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4253.     INLINE $205F, $4E90;
  4254.     {$ENDC}
  4255.  
  4256. FUNCTION CallForEachAttrTypeProc(clientData: LONGINT; {CONST}VAR attrType: AttributeType; userRoutine: ForEachAttrTypeUPP): BOOLEAN;
  4257.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4258.     INLINE $205F, $4E90;
  4259.     {$ENDC}
  4260.  
  4261. FUNCTION CallForEachRecordIDProc(clientData: LONGINT; {CONST}VAR recordID: RecordID; userRoutine: ForEachRecordIDUPP): BOOLEAN;
  4262.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4263.     INLINE $205F, $4E90;
  4264.     {$ENDC}
  4265.  
  4266. FUNCTION CallForEachDirectoryProc(clientData: LONGINT; {CONST}VAR dirName: DirectoryName; {CONST}VAR discriminator: DirDiscriminator; features: DirGestalt; userRoutine: ForEachDirectoryUPP): BOOLEAN;
  4267.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4268.     INLINE $205F, $4E90;
  4269.     {$ENDC}
  4270.  
  4271. FUNCTION CallForEachADAPDirectoryProc(clientData: LONGINT; {CONST}VAR dirName: DirectoryName; {CONST}VAR discriminator: DirDiscriminator; features: DirGestalt; serverHint: AddrBlock; userRoutine: ForEachADAPDirectoryUPP): BOOLEAN;
  4272.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4273.     INLINE $205F, $4E90;
  4274.     {$ENDC}
  4275.  
  4276. FUNCTION CallForEachDNodeAccessControlProc(clientData: LONGINT; {CONST}VAR dsObj: DSSpec; activeDnodeAccMask: AccessMask; defaultRecordAccMask: AccessMask; defaultAttributeAccMask: AccessMask; userRoutine: ForEachDNodeAccessControlUPP): BOOLEAN;
  4277.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4278.     INLINE $205F, $4E90;
  4279.     {$ENDC}
  4280.  
  4281. FUNCTION CallForEachRecordAccessControlProc(clientData: LONGINT; {CONST}VAR dsObj: DSSpec; activeDnodeAccMask: AccessMask; activeRecordAccMask: AccessMask; defaultAttributeAccMask: AccessMask; userRoutine: ForEachRecordAccessControlUPP): BOOLEAN;
  4282.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4283.     INLINE $205F, $4E90;
  4284.     {$ENDC}
  4285.  
  4286. FUNCTION CallForEachAttributeAccessControlProc(clientData: LONGINT; {CONST}VAR dsObj: DSSpec; activeDnodeAccMask: AccessMask; activeRecordAccMask: AccessMask; activeAttributeAccMask: AccessMask; userRoutine: ForEachAttributeAccessControlUPP): BOOLEAN;
  4287.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4288.     INLINE $205F, $4E90;
  4289.     {$ENDC}
  4290.  
  4291. FUNCTION CallDSAMDirProc(dsamData: UNIV Ptr; paramBlock: DirParamBlockPtr; async: BOOLEAN; userRoutine: DSAMDirUPP): OSErr;
  4292.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4293.     INLINE $205F, $4E90;
  4294.     {$ENDC}
  4295.  
  4296. FUNCTION CallDSAMDirParseProc(dsamData: UNIV Ptr; paramBlock: DirParamBlockPtr; async: BOOLEAN; userRoutine: DSAMDirParseUPP): OSErr;
  4297.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4298.     INLINE $205F, $4E90;
  4299.     {$ENDC}
  4300.  
  4301. FUNCTION CallDSAMAuthProc(dsamData: UNIV Ptr; pb: AuthParamBlockPtr; async: BOOLEAN; userRoutine: DSAMAuthUPP): OSErr;
  4302.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4303.     INLINE $205F, $4E90;
  4304.     {$ENDC}
  4305.  
  4306. FUNCTION NewAuthIOCompletionProc(userRoutine: AuthIOCompletionProcPtr): AuthIOCompletionUPP;
  4307.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4308.     INLINE $2E9F;
  4309.     {$ENDC}
  4310.  
  4311. FUNCTION NewNotificationProc(userRoutine: NotificationProcPtr): NotificationUPP;
  4312.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4313.     INLINE $2E9F;
  4314.     {$ENDC}
  4315.  
  4316. FUNCTION NewDirIOCompletionProc(userRoutine: DirIOCompletionProcPtr): DirIOCompletionUPP;
  4317.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4318.     INLINE $2E9F;
  4319.     {$ENDC}
  4320.  
  4321. FUNCTION NewForEachDirEnumSpecProc(userRoutine: ForEachDirEnumSpecProcPtr): ForEachDirEnumSpecUPP;
  4322.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4323.     INLINE $2E9F;
  4324.     {$ENDC}
  4325.  
  4326. FUNCTION NewForEachRecordProc(userRoutine: ForEachRecordProcPtr): ForEachRecordUPP;
  4327.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4328.     INLINE $2E9F;
  4329.     {$ENDC}
  4330.  
  4331. FUNCTION NewForEachLookupRecordIDProc(userRoutine: ForEachLookupRecordIDProcPtr): ForEachLookupRecordIDUPP;
  4332.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4333.     INLINE $2E9F;
  4334.     {$ENDC}
  4335.  
  4336. FUNCTION NewForEachAttrTypeLookupProc(userRoutine: ForEachAttrTypeLookupProcPtr): ForEachAttrTypeLookupUPP;
  4337.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4338.     INLINE $2E9F;
  4339.     {$ENDC}
  4340.  
  4341. FUNCTION NewForEachAttrValueProc(userRoutine: ForEachAttrValueProcPtr): ForEachAttrValueUPP;
  4342.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4343.     INLINE $2E9F;
  4344.     {$ENDC}
  4345.  
  4346. FUNCTION NewForEachAttrTypeProc(userRoutine: ForEachAttrTypeProcPtr): ForEachAttrTypeUPP;
  4347.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4348.     INLINE $2E9F;
  4349.     {$ENDC}
  4350.  
  4351. FUNCTION NewForEachRecordIDProc(userRoutine: ForEachRecordIDProcPtr): ForEachRecordIDUPP;
  4352.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4353.     INLINE $2E9F;
  4354.     {$ENDC}
  4355.  
  4356. FUNCTION NewForEachDirectoryProc(userRoutine: ForEachDirectoryProcPtr): ForEachDirectoryUPP;
  4357.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4358.     INLINE $2E9F;
  4359.     {$ENDC}
  4360.  
  4361. FUNCTION NewForEachADAPDirectoryProc(userRoutine: ForEachADAPDirectoryProcPtr): ForEachADAPDirectoryUPP;
  4362.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4363.     INLINE $2E9F;
  4364.     {$ENDC}
  4365.  
  4366. FUNCTION NewForEachDNodeAccessControlProc(userRoutine: ForEachDNodeAccessControlProcPtr): ForEachDNodeAccessControlUPP;
  4367.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4368.     INLINE $2E9F;
  4369.     {$ENDC}
  4370.  
  4371. FUNCTION NewForEachRecordAccessControlProc(userRoutine: ForEachRecordAccessControlProcPtr): ForEachRecordAccessControlUPP;
  4372.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4373.     INLINE $2E9F;
  4374.     {$ENDC}
  4375.  
  4376. FUNCTION NewForEachAttributeAccessControlProc(userRoutine: ForEachAttributeAccessControlProcPtr): ForEachAttributeAccessControlUPP;
  4377.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4378.     INLINE $2E9F;
  4379.     {$ENDC}
  4380.  
  4381. FUNCTION NewDSAMDirProc(userRoutine: DSAMDirProcPtr): DSAMDirUPP;
  4382.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4383.     INLINE $2E9F;
  4384.     {$ENDC}
  4385.  
  4386. FUNCTION NewDSAMDirParseProc(userRoutine: DSAMDirParseProcPtr): DSAMDirParseUPP;
  4387.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4388.     INLINE $2E9F;
  4389.     {$ENDC}
  4390.  
  4391. FUNCTION NewDSAMAuthProc(userRoutine: DSAMAuthProcPtr): DSAMAuthUPP;
  4392.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4393.     INLINE $2E9F;
  4394.     {$ENDC}
  4395. FUNCTION AuthBindSpecificIdentity(paramBlock: AuthParamBlockPtr; async: BOOLEAN): OSErr;
  4396.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4397.     INLINE $3F3C, $0200, $AA5E;
  4398.     {$ENDC}
  4399. FUNCTION AuthUnbindSpecificIdentity(paramBlock: AuthParamBlockPtr; async: BOOLEAN): OSErr;
  4400.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4401.     INLINE $3F3C, $0201, $AA5E;
  4402.     {$ENDC}
  4403. FUNCTION AuthResolveCreationID(paramBlock: AuthParamBlockPtr; async: BOOLEAN): OSErr;
  4404.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4405.     INLINE $3F3C, $0202, $AA5E;
  4406.     {$ENDC}
  4407. FUNCTION AuthGetSpecificIdentityInfo(paramBlock: AuthParamBlockPtr; async: BOOLEAN): OSErr;
  4408.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4409.     INLINE $3F3C, $0203, $AA5E;
  4410.     {$ENDC}
  4411. FUNCTION AuthAddKey(paramBlock: AuthParamBlockPtr; async: BOOLEAN): OSErr;
  4412.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4413.     INLINE $3F3C, $0207, $AA5E;
  4414.     {$ENDC}
  4415. FUNCTION AuthChangeKey(paramBlock: AuthParamBlockPtr; async: BOOLEAN): OSErr;
  4416.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4417.     INLINE $3F3C, $0208, $AA5E;
  4418.     {$ENDC}
  4419. FUNCTION AuthDeleteKey(paramBlock: AuthParamBlockPtr; async: BOOLEAN): OSErr;
  4420.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4421.     INLINE $3F3C, $0209, $AA5E;
  4422.     {$ENDC}
  4423. FUNCTION AuthPasswordToKey(paramBlock: AuthParamBlockPtr; async: BOOLEAN): OSErr;
  4424.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4425.     INLINE $3F3C, $020A, $AA5E;
  4426.     {$ENDC}
  4427. FUNCTION AuthGetCredentials(paramBlock: AuthParamBlockPtr; async: BOOLEAN): OSErr;
  4428.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4429.     INLINE $3F3C, $020B, $AA5E;
  4430.     {$ENDC}
  4431. FUNCTION AuthDecryptCredentials(paramBlock: AuthParamBlockPtr; async: BOOLEAN): OSErr;
  4432.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4433.     INLINE $3F3C, $020C, $AA5E;
  4434.     {$ENDC}
  4435. FUNCTION AuthMakeChallenge(paramBlock: AuthParamBlockPtr; async: BOOLEAN): OSErr;
  4436.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4437.     INLINE $3F3C, $020F, $AA5E;
  4438.     {$ENDC}
  4439. FUNCTION AuthMakeReply(paramBlock: AuthParamBlockPtr; async: BOOLEAN): OSErr;
  4440.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4441.     INLINE $3F3C, $0210, $AA5E;
  4442.     {$ENDC}
  4443. FUNCTION AuthVerifyReply(paramBlock: AuthParamBlockPtr; async: BOOLEAN): OSErr;
  4444.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4445.     INLINE $3F3C, $0211, $AA5E;
  4446.     {$ENDC}
  4447. FUNCTION AuthGetUTCTime(paramBlock: AuthParamBlockPtr; async: BOOLEAN): OSErr;
  4448.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4449.     INLINE $3F3C, $021A, $AA5E;
  4450.     {$ENDC}
  4451. FUNCTION AuthMakeProxy(paramBlock: AuthParamBlockPtr; async: BOOLEAN): OSErr;
  4452.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4453.     INLINE $3F3C, $0212, $AA5E;
  4454.     {$ENDC}
  4455. FUNCTION AuthTradeProxyForCredentials(paramBlock: AuthParamBlockPtr; async: BOOLEAN): OSErr;
  4456.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4457.     INLINE $3F3C, $0213, $AA5E;
  4458.     {$ENDC}
  4459. { Local Identity API }
  4460. FUNCTION AuthGetLocalIdentity(paramBlock: AuthParamBlockPtr; async: BOOLEAN): OSErr;
  4461.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4462.     INLINE $3F3C, $0204, $AA5E;
  4463.     {$ENDC}
  4464. FUNCTION AuthUnlockLocalIdentity(paramBlock: AuthParamBlockPtr; async: BOOLEAN): OSErr;
  4465.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4466.     INLINE $3F3C, $0214, $AA5E;
  4467.     {$ENDC}
  4468. FUNCTION AuthLockLocalIdentity(paramBlock: AuthParamBlockPtr; async: BOOLEAN): OSErr;
  4469.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4470.     INLINE $3F3C, $0215, $AA5E;
  4471.     {$ENDC}
  4472. FUNCTION AuthAddToLocalIdentityQueue(paramBlock: AuthParamBlockPtr; async: BOOLEAN): OSErr;
  4473.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4474.     INLINE $3F3C, $0205, $AA5E;
  4475.     {$ENDC}
  4476. FUNCTION AuthRemoveFromLocalIdentityQueue(paramBlock: AuthParamBlockPtr; async: BOOLEAN): OSErr;
  4477.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4478.     INLINE $3F3C, $0206, $AA5E;
  4479.     {$ENDC}
  4480. FUNCTION AuthSetupLocalIdentity(paramBlock: AuthParamBlockPtr; async: BOOLEAN): OSErr;
  4481.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4482.     INLINE $3F3C, $0216, $AA5E;
  4483.     {$ENDC}
  4484. FUNCTION AuthChangeLocalIdentity(paramBlock: AuthParamBlockPtr; async: BOOLEAN): OSErr;
  4485.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4486.     INLINE $3F3C, $0217, $AA5E;
  4487.     {$ENDC}
  4488. FUNCTION AuthRemoveLocalIdentity(paramBlock: AuthParamBlockPtr; async: BOOLEAN): OSErr;
  4489.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4490.     INLINE $3F3C, $0218, $AA5E;
  4491.     {$ENDC}
  4492. FUNCTION DirAddRecord(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4493.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4494.     INLINE $3F3C, $0109, $AA5E;
  4495.     {$ENDC}
  4496. FUNCTION DirDeleteRecord(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4497.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4498.     INLINE $3F3C, $010A, $AA5E;
  4499.     {$ENDC}
  4500. FUNCTION DirEnumerateGet(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4501.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4502.     INLINE $3F3C, $0111, $AA5E;
  4503.     {$ENDC}
  4504. FUNCTION DirEnumerateParse(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4505.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4506.     INLINE $3F3C, $0101, $AA5E;
  4507.     {$ENDC}
  4508. FUNCTION DirFindRecordGet(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4509.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4510.     INLINE $3F3C, $0140, $AA5E;
  4511.     {$ENDC}
  4512. FUNCTION DirFindRecordParse(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4513.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4514.     INLINE $3F3C, $0141, $AA5E;
  4515.     {$ENDC}
  4516. FUNCTION DirLookupGet(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4517.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4518.     INLINE $3F3C, $0117, $AA5E;
  4519.     {$ENDC}
  4520. FUNCTION DirLookupParse(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4521.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4522.     INLINE $3F3C, $0102, $AA5E;
  4523.     {$ENDC}
  4524. FUNCTION DirAddAttributeValue(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4525.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4526.     INLINE $3F3C, $010B, $AA5E;
  4527.     {$ENDC}
  4528. FUNCTION DirDeleteAttributeValue(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4529.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4530.     INLINE $3F3C, $010C, $AA5E;
  4531.     {$ENDC}
  4532. FUNCTION DirDeleteAttributeType(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4533.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4534.     INLINE $3F3C, $0130, $AA5E;
  4535.     {$ENDC}
  4536. FUNCTION DirChangeAttributeValue(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4537.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4538.     INLINE $3F3C, $010D, $AA5E;
  4539.     {$ENDC}
  4540. FUNCTION DirVerifyAttributeValue(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4541.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4542.     INLINE $3F3C, $010E, $AA5E;
  4543.     {$ENDC}
  4544. FUNCTION DirFindValue(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4545.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4546.     INLINE $3F3C, $0126, $AA5E;
  4547.     {$ENDC}
  4548. FUNCTION DirEnumerateAttributeTypesGet(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4549.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4550.     INLINE $3F3C, $0112, $AA5E;
  4551.     {$ENDC}
  4552. FUNCTION DirEnumerateAttributeTypesParse(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4553.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4554.     INLINE $3F3C, $0103, $AA5E;
  4555.     {$ENDC}
  4556. FUNCTION DirAddPseudonym(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4557.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4558.     INLINE $3F3C, $010F, $AA5E;
  4559.     {$ENDC}
  4560. FUNCTION DirDeletePseudonym(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4561.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4562.     INLINE $3F3C, $0110, $AA5E;
  4563.     {$ENDC}
  4564. FUNCTION DirAddAlias(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4565.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4566.     INLINE $3F3C, $011C, $AA5E;
  4567.     {$ENDC}
  4568. FUNCTION DirEnumeratePseudonymGet(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4569.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4570.     INLINE $3F3C, $0113, $AA5E;
  4571.     {$ENDC}
  4572. FUNCTION DirEnumeratePseudonymParse(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4573.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4574.     INLINE $3F3C, $0104, $AA5E;
  4575.     {$ENDC}
  4576. FUNCTION DirGetNameAndType(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4577.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4578.     INLINE $3F3C, $0114, $AA5E;
  4579.     {$ENDC}
  4580. FUNCTION DirSetNameAndType(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4581.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4582.     INLINE $3F3C, $0115, $AA5E;
  4583.     {$ENDC}
  4584. FUNCTION DirGetRecordMetaInfo(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4585.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4586.     INLINE $3F3C, $0116, $AA5E;
  4587.     {$ENDC}
  4588. FUNCTION DirGetDNodeMetaInfo(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4589.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4590.     INLINE $3F3C, $0118, $AA5E;
  4591.     {$ENDC}
  4592. FUNCTION DirGetDirectoryInfo(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4593.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4594.     INLINE $3F3C, $0119, $AA5E;
  4595.     {$ENDC}
  4596. FUNCTION DirGetDNodeAccessControlGet(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4597.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4598.     INLINE $3F3C, $012A, $AA5E;
  4599.     {$ENDC}
  4600. FUNCTION DirGetDNodeAccessControlParse(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4601.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4602.     INLINE $3F3C, $012F, $AA5E;
  4603.     {$ENDC}
  4604. FUNCTION DirGetRecordAccessControlGet(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4605.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4606.     INLINE $3F3C, $012C, $AA5E;
  4607.     {$ENDC}
  4608. FUNCTION DirGetRecordAccessControlParse(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4609.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4610.     INLINE $3F3C, $0134, $AA5E;
  4611.     {$ENDC}
  4612. FUNCTION DirGetAttributeAccessControlGet(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4613.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4614.     INLINE $3F3C, $012E, $AA5E;
  4615.     {$ENDC}
  4616. FUNCTION DirGetAttributeAccessControlParse(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4617.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4618.     INLINE $3F3C, $0138, $AA5E;
  4619.     {$ENDC}
  4620. FUNCTION DirEnumerateDirectoriesGet(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4621.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4622.     INLINE $3F3C, $011A, $AA5E;
  4623.     {$ENDC}
  4624. FUNCTION DirEnumerateDirectoriesParse(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4625.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4626.     INLINE $3F3C, $0106, $AA5E;
  4627.     {$ENDC}
  4628. FUNCTION DirMapPathNameToDNodeNumber(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4629.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4630.     INLINE $3F3C, $0122, $AA5E;
  4631.     {$ENDC}
  4632. FUNCTION DirMapDNodeNumberToPathName(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4633.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4634.     INLINE $3F3C, $0123, $AA5E;
  4635.     {$ENDC}
  4636.  
  4637. FUNCTION DirGetLocalNetworkSpec(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4638.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4639.     INLINE $3F3C, $0124, $AA5E;
  4640.     {$ENDC}
  4641. FUNCTION DirGetDNodeInfo(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4642.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4643.     INLINE $3F3C, $0125, $AA5E;
  4644.     {$ENDC}
  4645.  
  4646. {  Trap Dispatchers for Personal Catalog and CSAM Extensions }
  4647. FUNCTION DirCreatePersonalDirectory(paramBlock: DirParamBlockPtr): OSErr;
  4648.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4649.     INLINE $7000, $1F00, $3F3C, $011F, $AA5E;
  4650.     {$ENDC}
  4651. FUNCTION DirOpenPersonalDirectory(paramBlock: DirParamBlockPtr): OSErr;
  4652.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4653.     INLINE $7000, $1F00, $3F3C, $011E, $AA5E;
  4654.     {$ENDC}
  4655. FUNCTION DirClosePersonalDirectory(paramBlock: DirParamBlockPtr): OSErr;
  4656.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4657.     INLINE $7000, $1F00, $3F3C, $0131, $AA5E;
  4658.     {$ENDC}
  4659. FUNCTION DirMakePersonalDirectoryRLI(paramBlock: DirParamBlockPtr): OSErr;
  4660.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4661.     INLINE $7000, $1F00, $3F3C, $0132, $AA5E;
  4662.     {$ENDC}
  4663. FUNCTION DirAddDSAM(paramBlock: DirParamBlockPtr): OSErr;
  4664.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4665.     INLINE $7000, $1F00, $3F3C, $011D, $AA5E;
  4666.     {$ENDC}
  4667. FUNCTION DirInstantiateDSAM(paramBlock: DirParamBlockPtr): OSErr;
  4668.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4669.     INLINE $7000, $1F00, $3F3C, $0127, $AA5E;
  4670.     {$ENDC}
  4671.  
  4672. FUNCTION DirRemoveDSAM(paramBlock: DirParamBlockPtr): OSErr;
  4673.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4674.     INLINE $7000, $1F00, $3F3C, $0120, $AA5E;
  4675.     {$ENDC}
  4676. FUNCTION DirAddDSAMDirectory(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4677.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4678.     INLINE $3F3C, $0133, $AA5E;
  4679.     {$ENDC}
  4680. FUNCTION DirGetExtendedDirectoriesInfo(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4681.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4682.     INLINE $3F3C, $0136, $AA5E;
  4683.     {$ENDC}
  4684. FUNCTION DirGetDirectoryIcon(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4685.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4686.     INLINE $3F3C, $0121, $AA5E;
  4687.     {$ENDC}
  4688.  
  4689. FUNCTION DirAddADAPDirectory(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4690.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4691.     INLINE $3F3C, $0137, $AA5E;
  4692.     {$ENDC}
  4693. FUNCTION DirRemoveDirectory(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4694.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4695.     INLINE $3F3C, $0135, $AA5E;
  4696.     {$ENDC}
  4697. FUNCTION DirNetSearchADAPDirectoriesGet(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4698.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4699.     INLINE $3F3C, $0108, $AA5E;
  4700.     {$ENDC}
  4701. FUNCTION DirNetSearchADAPDirectoriesParse(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4702.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4703.     INLINE $3F3C, $0105, $AA5E;
  4704.     {$ENDC}
  4705. FUNCTION DirFindADAPDirectoryByNetSearch(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4706.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4707.     INLINE $3F3C, $0107, $AA5E;
  4708.     {$ENDC}
  4709. FUNCTION DirGetOCESetupRefNum(paramBlock: DirParamBlockPtr; async: BOOLEAN): OSErr;
  4710.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4711.     INLINE $3F3C, $0128, $AA5E;
  4712.     {$ENDC}
  4713. FUNCTION DirAbort(paramBlock: DirParamBlockPtr): OSErr;
  4714.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4715.     INLINE $7000, $1F00, $3F3C, $011B, $AA5E;
  4716.     {$ENDC}
  4717. FUNCTION OCESetupAddDirectoryInfo(paramBlock: AuthParamBlockPtr; async: BOOLEAN): OSErr;
  4718.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4719.     INLINE $3F3C, $0219, $AA5E;
  4720.     {$ENDC}
  4721. FUNCTION OCESetupChangeDirectoryInfo(paramBlock: AuthParamBlockPtr; async: BOOLEAN): OSErr;
  4722.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4723.     INLINE $3F3C, $021B, $AA5E;
  4724.     {$ENDC}
  4725. FUNCTION OCESetupRemoveDirectoryInfo(paramBlock: AuthParamBlockPtr; async: BOOLEAN): OSErr;
  4726.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4727.     INLINE $3F3C, $020D, $AA5E;
  4728.     {$ENDC}
  4729. FUNCTION OCESetupGetDirectoryInfo(paramBlock: AuthParamBlockPtr; async: BOOLEAN): OSErr;
  4730.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  4731.     INLINE $3F3C, $020E, $AA5E;
  4732.     {$ENDC}
  4733. {$ALIGN RESET}
  4734. {$POP}
  4735.  
  4736. {$SETC UsingIncludes := OCEAuthDirIncludes}
  4737.  
  4738. {$ENDC} {__OCEAUTHDIR__}
  4739.  
  4740. {$IFC NOT UsingIncludes}
  4741.  END.
  4742. {$ENDC}
  4743.